{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 441,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<class 'netCDF4._netCDF4.Dataset'>\n",
      "root group (NETCDF4 data model, file format HDF5):\n",
      "    dimensions(sizes): year(4645), month(36)\n",
      "    variables(dimensions): float64 nino(year, month), int32 year(year), int32 month(month)\n",
      "    groups: \n",
      "<class 'netCDF4._netCDF4.Dataset'>\n",
      "root group (NETCDF4 data model, file format HDF5):\n",
      "    dimensions(sizes): year(4645), month(36), lat(24), lon(72)\n",
      "    variables(dimensions): float64 sst(year, month, lat, lon), float64 t300(year, month, lat, lon), float64 ua(year, month, lat, lon), float64 va(year, month, lat, lon), int32 year(year), int32 month(month), float32 lat(lat), float32 lon(lon)\n",
      "    groups: \n",
      "<class 'netCDF4._netCDF4.Dataset'>\n",
      "root group (NETCDF4 data model, file format HDF5):\n",
      "    dimensions(sizes): year(100), month(36)\n",
      "    variables(dimensions): float64 nino(year, month), int32 year(year), int32 month(month)\n",
      "    groups: \n",
      "<class 'netCDF4._netCDF4.Dataset'>\n",
      "root group (NETCDF4 data model, file format HDF5):\n",
      "    dimensions(sizes): year(100), month(36), lat(24), lon(72)\n",
      "    variables(dimensions): float32 sst(year, month, lat, lon), float32 t300(year, month, lat, lon), float64 ua(year, month, lat, lon), float64 va(year, month, lat, lon), int32 year(year), int32 month(month), float64 lat(lat), float64 lon(lon)\n",
      "    groups: \n"
     ]
    }
   ],
   "source": [
    "import pandas as pd\n",
    "import numpy as np\n",
    "import netCDF4 as nc\n",
    "import os\n",
    "import xarray as xr\n",
    "import datetime\n",
    "#批量读文件还没写完，暂时没用\n",
    "train_dir = '../tcdata/enso_round1_train_20210201'\n",
    "for i in os.listdir(train_dir):\n",
    "    if i.endswith('.nc'):\n",
    "        x = nc.Dataset(train_dir + '/' + i)\n",
    "        print(x)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 442,
   "metadata": {},
   "outputs": [],
   "source": [
    "#读读CIMP_lable信息  先把train中的数据转换到dataframe中再加上lable里的nino\n",
    "a=nc.Dataset('../tcdata/enso_round1_train_20210201/CMIP_label.nc')\n",
    "dica={}\n",
    "for i in a.variables.keys():\n",
    "    dica[i]=a.variables[i][:].data"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 443,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div><svg style=\"position: absolute; width: 0; height: 0; overflow: hidden\">\n",
       "<defs>\n",
       "<symbol id=\"icon-database\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M16 0c-8.837 0-16 2.239-16 5v4c0 2.761 7.163 5 16 5s16-2.239 16-5v-4c0-2.761-7.163-5-16-5z\"></path>\n",
       "<path d=\"M16 17c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "<path d=\"M16 26c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "</symbol>\n",
       "<symbol id=\"icon-file-text2\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M28.681 7.159c-0.694-0.947-1.662-2.053-2.724-3.116s-2.169-2.030-3.116-2.724c-1.612-1.182-2.393-1.319-2.841-1.319h-15.5c-1.378 0-2.5 1.121-2.5 2.5v27c0 1.378 1.122 2.5 2.5 2.5h23c1.378 0 2.5-1.122 2.5-2.5v-19.5c0-0.448-0.137-1.23-1.319-2.841zM24.543 5.457c0.959 0.959 1.712 1.825 2.268 2.543h-4.811v-4.811c0.718 0.556 1.584 1.309 2.543 2.268zM28 29.5c0 0.271-0.229 0.5-0.5 0.5h-23c-0.271 0-0.5-0.229-0.5-0.5v-27c0-0.271 0.229-0.5 0.5-0.5 0 0 15.499-0 15.5 0v7c0 0.552 0.448 1 1 1h7v19.5z\"></path>\n",
       "<path d=\"M23 26h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 22h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 18h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "</symbol>\n",
       "</defs>\n",
       "</svg>\n",
       "<style>/* CSS stylesheet for displaying xarray objects in jupyterlab.\n",
       " *\n",
       " */\n",
       "\n",
       ":root {\n",
       "  --xr-font-color0: var(--jp-content-font-color0, rgba(0, 0, 0, 1));\n",
       "  --xr-font-color2: var(--jp-content-font-color2, rgba(0, 0, 0, 0.54));\n",
       "  --xr-font-color3: var(--jp-content-font-color3, rgba(0, 0, 0, 0.38));\n",
       "  --xr-border-color: var(--jp-border-color2, #e0e0e0);\n",
       "  --xr-disabled-color: var(--jp-layout-color3, #bdbdbd);\n",
       "  --xr-background-color: var(--jp-layout-color0, white);\n",
       "  --xr-background-color-row-even: var(--jp-layout-color1, white);\n",
       "  --xr-background-color-row-odd: var(--jp-layout-color2, #eeeeee);\n",
       "}\n",
       "\n",
       "html[theme=dark],\n",
       "body.vscode-dark {\n",
       "  --xr-font-color0: rgba(255, 255, 255, 1);\n",
       "  --xr-font-color2: rgba(255, 255, 255, 0.54);\n",
       "  --xr-font-color3: rgba(255, 255, 255, 0.38);\n",
       "  --xr-border-color: #1F1F1F;\n",
       "  --xr-disabled-color: #515151;\n",
       "  --xr-background-color: #111111;\n",
       "  --xr-background-color-row-even: #111111;\n",
       "  --xr-background-color-row-odd: #313131;\n",
       "}\n",
       "\n",
       ".xr-wrap {\n",
       "  display: block;\n",
       "  min-width: 300px;\n",
       "  max-width: 700px;\n",
       "}\n",
       "\n",
       ".xr-text-repr-fallback {\n",
       "  /* fallback to plain text repr when CSS is not injected (untrusted notebook) */\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-header {\n",
       "  padding-top: 6px;\n",
       "  padding-bottom: 6px;\n",
       "  margin-bottom: 4px;\n",
       "  border-bottom: solid 1px var(--xr-border-color);\n",
       "}\n",
       "\n",
       ".xr-header > div,\n",
       ".xr-header > ul {\n",
       "  display: inline;\n",
       "  margin-top: 0;\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-obj-type,\n",
       ".xr-array-name {\n",
       "  margin-left: 2px;\n",
       "  margin-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-obj-type {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-sections {\n",
       "  padding-left: 0 !important;\n",
       "  display: grid;\n",
       "  grid-template-columns: 150px auto auto 1fr 20px 20px;\n",
       "}\n",
       "\n",
       ".xr-section-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-section-item input {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-item input + label {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label {\n",
       "  cursor: pointer;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label:hover {\n",
       "  color: var(--xr-font-color0);\n",
       "}\n",
       "\n",
       ".xr-section-summary {\n",
       "  grid-column: 1;\n",
       "  color: var(--xr-font-color2);\n",
       "  font-weight: 500;\n",
       "}\n",
       "\n",
       ".xr-section-summary > span {\n",
       "  display: inline-block;\n",
       "  padding-left: 0.5em;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in + label:before {\n",
       "  display: inline-block;\n",
       "  content: '►';\n",
       "  font-size: 11px;\n",
       "  width: 15px;\n",
       "  text-align: center;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label:before {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label:before {\n",
       "  content: '▼';\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label > span {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-summary,\n",
       ".xr-section-inline-details {\n",
       "  padding-top: 4px;\n",
       "  padding-bottom: 4px;\n",
       "}\n",
       "\n",
       ".xr-section-inline-details {\n",
       "  grid-column: 2 / -1;\n",
       "}\n",
       "\n",
       ".xr-section-details {\n",
       "  display: none;\n",
       "  grid-column: 1 / -1;\n",
       "  margin-bottom: 5px;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked ~ .xr-section-details {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-array-wrap {\n",
       "  grid-column: 1 / -1;\n",
       "  display: grid;\n",
       "  grid-template-columns: 20px auto;\n",
       "}\n",
       "\n",
       ".xr-array-wrap > label {\n",
       "  grid-column: 1;\n",
       "  vertical-align: top;\n",
       "}\n",
       "\n",
       ".xr-preview {\n",
       "  color: var(--xr-font-color3);\n",
       "}\n",
       "\n",
       ".xr-array-preview,\n",
       ".xr-array-data {\n",
       "  padding: 0 5px !important;\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-array-data,\n",
       ".xr-array-in:checked ~ .xr-array-preview {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-array-in:checked ~ .xr-array-data,\n",
       ".xr-array-preview {\n",
       "  display: inline-block;\n",
       "}\n",
       "\n",
       ".xr-dim-list {\n",
       "  display: inline-block !important;\n",
       "  list-style: none;\n",
       "  padding: 0 !important;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list li {\n",
       "  display: inline-block;\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list:before {\n",
       "  content: '(';\n",
       "}\n",
       "\n",
       ".xr-dim-list:after {\n",
       "  content: ')';\n",
       "}\n",
       "\n",
       ".xr-dim-list li:not(:last-child):after {\n",
       "  content: ',';\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-has-index {\n",
       "  font-weight: bold;\n",
       "}\n",
       "\n",
       ".xr-var-list,\n",
       ".xr-var-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-var-item > div,\n",
       ".xr-var-item label,\n",
       ".xr-var-item > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-even);\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-var-item > .xr-var-name:hover span {\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-var-list > li:nth-child(odd) > div,\n",
       ".xr-var-list > li:nth-child(odd) > label,\n",
       ".xr-var-list > li:nth-child(odd) > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-odd);\n",
       "}\n",
       "\n",
       ".xr-var-name {\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-var-dims {\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-var-dtype {\n",
       "  grid-column: 3;\n",
       "  text-align: right;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-var-preview {\n",
       "  grid-column: 4;\n",
       "}\n",
       "\n",
       ".xr-var-name,\n",
       ".xr-var-dims,\n",
       ".xr-var-dtype,\n",
       ".xr-preview,\n",
       ".xr-attrs dt {\n",
       "  white-space: nowrap;\n",
       "  overflow: hidden;\n",
       "  text-overflow: ellipsis;\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-var-name:hover,\n",
       ".xr-var-dims:hover,\n",
       ".xr-var-dtype:hover,\n",
       ".xr-attrs dt:hover {\n",
       "  overflow: visible;\n",
       "  width: auto;\n",
       "  z-index: 1;\n",
       "}\n",
       "\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  display: none;\n",
       "  background-color: var(--xr-background-color) !important;\n",
       "  padding-bottom: 5px !important;\n",
       "}\n",
       "\n",
       ".xr-var-attrs-in:checked ~ .xr-var-attrs,\n",
       ".xr-var-data-in:checked ~ .xr-var-data {\n",
       "  display: block;\n",
       "}\n",
       "\n",
       ".xr-var-data > table {\n",
       "  float: right;\n",
       "}\n",
       "\n",
       ".xr-var-name span,\n",
       ".xr-var-data,\n",
       ".xr-attrs {\n",
       "  padding-left: 25px !important;\n",
       "}\n",
       "\n",
       ".xr-attrs,\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  grid-column: 1 / -1;\n",
       "}\n",
       "\n",
       "dl.xr-attrs {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  display: grid;\n",
       "  grid-template-columns: 125px auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt, dd {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  float: left;\n",
       "  padding-right: 10px;\n",
       "  width: auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt {\n",
       "  font-weight: normal;\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-attrs dt:hover span {\n",
       "  display: inline-block;\n",
       "  background: var(--xr-background-color);\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-attrs dd {\n",
       "  grid-column: 2;\n",
       "  white-space: pre-wrap;\n",
       "  word-break: break-all;\n",
       "}\n",
       "\n",
       ".xr-icon-database,\n",
       ".xr-icon-file-text2 {\n",
       "  display: inline-block;\n",
       "  vertical-align: middle;\n",
       "  width: 1em;\n",
       "  height: 1.5em !important;\n",
       "  stroke-width: 0;\n",
       "  stroke: currentColor;\n",
       "  fill: currentColor;\n",
       "}\n",
       "</style><pre class='xr-text-repr-fallback'>&lt;xarray.Dataset&gt;\n",
       "Dimensions:  (month: 36, year: 4645)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 ... 4639 4640 4641 4642 4643 4644 4645\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 ... 28 29 30 31 32 33 34 35 36\n",
       "Data variables:\n",
       "    nino     (year, month) float64 ...</pre><div class='xr-wrap' hidden><div class='xr-header'><div class='xr-obj-type'>xarray.Dataset</div></div><ul class='xr-sections'><li class='xr-section-item'><input id='section-929ab27d-7530-4f34-b93d-49ce05aad16d' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-929ab27d-7530-4f34-b93d-49ce05aad16d' class='xr-section-summary'  title='Expand/collapse section'>Dimensions:</label><div class='xr-section-inline-details'><ul class='xr-dim-list'><li><span class='xr-has-index'>month</span>: 36</li><li><span class='xr-has-index'>year</span>: 4645</li></ul></div><div class='xr-section-details'></div></li><li class='xr-section-item'><input id='section-3cbdb1c6-703a-4ade-99fd-363afda21d98' class='xr-section-summary-in' type='checkbox'  checked><label for='section-3cbdb1c6-703a-4ade-99fd-363afda21d98' class='xr-section-summary' >Coordinates: <span>(2)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>year</span></div><div class='xr-var-dims'>(year)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 ... 4642 4643 4644 4645</div><input id='attrs-d3484c36-91f0-482e-a374-33729e8b74a6' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-d3484c36-91f0-482e-a374-33729e8b74a6' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-87a82b47-3b2d-4dbb-b89e-ea4a6ca569fc' class='xr-var-data-in' type='checkbox'><label for='data-87a82b47-3b2d-4dbb-b89e-ea4a6ca569fc' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([   1,    2,    3, ..., 4643, 4644, 4645], dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>month</span></div><div class='xr-var-dims'>(month)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 7 ... 31 32 33 34 35 36</div><input id='attrs-6ea497ea-9898-49ae-bd91-300eff239828' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-6ea497ea-9898-49ae-bd91-300eff239828' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-33d9aa3a-9f72-4a13-a23c-1c3c3fb40405' class='xr-var-data-in' type='checkbox'><label for='data-33d9aa3a-9f72-4a13-a23c-1c3c3fb40405' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12, 13, 14, 15, 16, 17, 18,\n",
       "       19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36],\n",
       "      dtype=int32)</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-8269d818-70f0-4388-b96a-0f9d2a1c8d40' class='xr-section-summary-in' type='checkbox'  checked><label for='section-8269d818-70f0-4388-b96a-0f9d2a1c8d40' class='xr-section-summary' >Data variables: <span>(1)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span>nino</span></div><div class='xr-var-dims'>(year, month)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-0dc95d90-b0d8-4811-a6fb-7b549ee25075' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-0dc95d90-b0d8-4811-a6fb-7b549ee25075' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-92cde8f1-6164-401d-a33f-ed0c735a7b51' class='xr-var-data-in' type='checkbox'><label for='data-92cde8f1-6164-401d-a33f-ed0c735a7b51' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[167220 values with dtype=float64]</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-a02b88cf-8a6a-413c-8d75-94665a59e07f' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-a02b88cf-8a6a-413c-8d75-94665a59e07f' class='xr-section-summary'  title='Expand/collapse section'>Attributes: <span>(0)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><dl class='xr-attrs'></dl></div></li></ul></div></div>"
      ],
      "text/plain": [
       "<xarray.Dataset>\n",
       "Dimensions:  (month: 36, year: 4645)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 ... 4639 4640 4641 4642 4643 4644 4645\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 ... 28 29 30 31 32 33 34 35 36\n",
       "Data variables:\n",
       "    nino     (year, month) float64 ..."
      ]
     },
     "execution_count": 443,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "A= xr.open_dataset(xr.backends.NetCDF4DataStore(a))\n",
    "A"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 444,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'nino': array([[-0.26102549, -0.13325377, -0.01483156, ...,  0.70016259,\n",
       "          0.69692588,  0.62087137],\n",
       "        [-0.51252842, -0.67330021, -0.69312692, ..., -3.32816887,\n",
       "         -3.33858109, -3.00591755],\n",
       "        [-0.16938901,  0.16518302,  0.42523685, ..., -0.21898462,\n",
       "         -0.15724176, -0.03204625],\n",
       "        ...,\n",
       "        [-0.16746233,  0.02371221,  0.19209623, ..., -0.45745715,\n",
       "         -0.4982231 , -0.43920282],\n",
       "        [ 0.63583368,  0.6991865 ,  0.82033938, ..., -0.66224277,\n",
       "         -0.65602088, -0.60984963],\n",
       "        [ 0.65862387,  0.48303536,  0.41316095, ...,  0.56690937,\n",
       "          0.63597536,  0.73177081]]),\n",
       " 'year': array([   1,    2,    3, ..., 4643, 4644, 4645], dtype=int32),\n",
       " 'month': array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12, 13, 14, 15, 16, 17,\n",
       "        18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,\n",
       "        35, 36], dtype=int32)}"
      ]
     },
     "execution_count": 444,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "dica"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 445,
   "metadata": {},
   "outputs": [],
   "source": [
    "b=nc.Dataset('../tcdata/enso_round1_train_20210201/CMIP_train.nc')\n",
    "dicb={}\n",
    "for i in b.variables.keys():\n",
    "    dicb[i]=b.variables[i][:]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 446,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "dict_keys(['sst', 't300', 'ua', 'va', 'year', 'month', 'lat', 'lon'])"
      ]
     },
     "execution_count": 446,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "dicb.keys()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 507,
   "metadata": {},
   "outputs": [],
   "source": [
    "B= xr.open_dataset(xr.backends.NetCDF4DataStore(b))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 519,
   "metadata": {},
   "outputs": [],
   "source": [
    "CMIP=B\n",
    "CMIP['nino']=(('year','month'),A['nino'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 520,
   "metadata": {},
   "outputs": [],
   "source": [
    "CMIP=CMIP.drop_sel(month=np.arange(13,37))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 521,
   "metadata": {},
   "outputs": [],
   "source": [
    "#下面先分割模式再拼时间\n",
    "#CMIP.expand_dims(\"mode\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 522,
   "metadata": {},
   "outputs": [],
   "source": [
    "CMIPdf=CMIP.to_dataframe()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 528,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th>sst</th>\n",
       "      <th>t300</th>\n",
       "      <th>ua</th>\n",
       "      <th>va</th>\n",
       "      <th>nino</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>lat</th>\n",
       "      <th>lon</th>\n",
       "      <th>month</th>\n",
       "      <th>year</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th rowspan=\"5\" valign=\"top\">-55.0</th>\n",
       "      <th rowspan=\"5\" valign=\"top\">0.0</th>\n",
       "      <th rowspan=\"5\" valign=\"top\">1</th>\n",
       "      <th>1</th>\n",
       "      <td>0.346436</td>\n",
       "      <td>-0.244890</td>\n",
       "      <td>-1.680264</td>\n",
       "      <td>-0.489486</td>\n",
       "      <td>-0.261025</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>-0.493941</td>\n",
       "      <td>-0.165055</td>\n",
       "      <td>2.115858</td>\n",
       "      <td>0.994749</td>\n",
       "      <td>-0.512528</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>-0.018142</td>\n",
       "      <td>-0.261186</td>\n",
       "      <td>-1.463467</td>\n",
       "      <td>1.306921</td>\n",
       "      <td>-0.169389</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>1.050851</td>\n",
       "      <td>0.251320</td>\n",
       "      <td>0.169948</td>\n",
       "      <td>0.310134</td>\n",
       "      <td>0.363714</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>0.449654</td>\n",
       "      <td>0.393005</td>\n",
       "      <td>4.141575</td>\n",
       "      <td>-0.783133</td>\n",
       "      <td>-2.557616</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                           sst      t300        ua        va      nino\n",
       "lat   lon month year                                                  \n",
       "-55.0 0.0 1     1     0.346436 -0.244890 -1.680264 -0.489486 -0.261025\n",
       "                2    -0.493941 -0.165055  2.115858  0.994749 -0.512528\n",
       "                3    -0.018142 -0.261186 -1.463467  1.306921 -0.169389\n",
       "                4     1.050851  0.251320  0.169948  0.310134  0.363714\n",
       "                5     0.449654  0.393005  4.141575 -0.783133 -2.557616"
      ]
     },
     "execution_count": 528,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "CMIPdf.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 533,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "sst     0.346436\n",
       "t300   -0.244890\n",
       "ua     -1.680264\n",
       "va     -0.489486\n",
       "nino   -0.261025\n",
       "Name: (-55.0, 0.0, 1, 1), dtype: float64"
      ]
     },
     "execution_count": 533,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "CMIPdf.loc[(-55.0,0,1,1)]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 550,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>lat</th>\n",
       "      <th>lon</th>\n",
       "      <th>month</th>\n",
       "      <th>year</th>\n",
       "      <th>mode</th>\n",
       "      <th>sst</th>\n",
       "      <th>t300</th>\n",
       "      <th>ua</th>\n",
       "      <th>va</th>\n",
       "      <th>nino</th>\n",
       "      <th>day</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>1</td>\n",
       "      <td>60001</td>\n",
       "      <td>0.346436</td>\n",
       "      <td>-0.244890</td>\n",
       "      <td>-1.680264</td>\n",
       "      <td>-0.489486</td>\n",
       "      <td>-0.261025</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>60001</td>\n",
       "      <td>-0.493941</td>\n",
       "      <td>-0.165055</td>\n",
       "      <td>2.115858</td>\n",
       "      <td>0.994749</td>\n",
       "      <td>-0.512528</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>3</td>\n",
       "      <td>60001</td>\n",
       "      <td>-0.018142</td>\n",
       "      <td>-0.261186</td>\n",
       "      <td>-1.463467</td>\n",
       "      <td>1.306921</td>\n",
       "      <td>-0.169389</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>4</td>\n",
       "      <td>60001</td>\n",
       "      <td>1.050851</td>\n",
       "      <td>0.251320</td>\n",
       "      <td>0.169948</td>\n",
       "      <td>0.310134</td>\n",
       "      <td>0.363714</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>5</td>\n",
       "      <td>60001</td>\n",
       "      <td>0.449654</td>\n",
       "      <td>0.393005</td>\n",
       "      <td>4.141575</td>\n",
       "      <td>-0.783133</td>\n",
       "      <td>-2.557616</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    lat  lon  month  year   mode       sst      t300        ua        va  \\\n",
       "0 -55.0  0.0      1     1  60001  0.346436 -0.244890 -1.680264 -0.489486   \n",
       "1 -55.0  0.0      1     2  60001 -0.493941 -0.165055  2.115858  0.994749   \n",
       "2 -55.0  0.0      1     3  60001 -0.018142 -0.261186 -1.463467  1.306921   \n",
       "3 -55.0  0.0      1     4  60001  1.050851  0.251320  0.169948  0.310134   \n",
       "4 -55.0  0.0      1     5  60001  0.449654  0.393005  4.141575 -0.783133   \n",
       "\n",
       "       nino  day  \n",
       "0 -0.261025    1  \n",
       "1 -0.512528    1  \n",
       "2 -0.169389    1  \n",
       "3  0.363714    1  \n",
       "4 -2.557616    1  "
      ]
     },
     "execution_count": 550,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "CMIPdf=CMIPdf.reset_index()\n",
    "CMIPdf.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 535,
   "metadata": {},
   "outputs": [],
   "source": [
    "def trans(x):\n",
    "    temp=10000*(6-(x>2265))+(x<2266)*((x-1)//151+1)+(x>2265)*(((x-1)-2265)//140+1)#这里返回str报错\n",
    "    #<2266:CMIP6 >2265:CMIP5\n",
    "    #编码顺序开始5，6，1表示CMIP5,6,SODA 后面表示模式 从1计数 \n",
    "    return temp\n",
    "CMIPdf['mode']=CMIPdf['year'].apply(trans)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 538,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>lat</th>\n",
       "      <th>lon</th>\n",
       "      <th>month</th>\n",
       "      <th>year</th>\n",
       "      <th>sst</th>\n",
       "      <th>t300</th>\n",
       "      <th>ua</th>\n",
       "      <th>va</th>\n",
       "      <th>nino</th>\n",
       "      <th>mode</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>1</td>\n",
       "      <td>0.346436</td>\n",
       "      <td>-0.244890</td>\n",
       "      <td>-1.680264</td>\n",
       "      <td>-0.489486</td>\n",
       "      <td>-0.261025</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>-0.493941</td>\n",
       "      <td>-0.165055</td>\n",
       "      <td>2.115858</td>\n",
       "      <td>0.994749</td>\n",
       "      <td>-0.512528</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>3</td>\n",
       "      <td>-0.018142</td>\n",
       "      <td>-0.261186</td>\n",
       "      <td>-1.463467</td>\n",
       "      <td>1.306921</td>\n",
       "      <td>-0.169389</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>4</td>\n",
       "      <td>1.050851</td>\n",
       "      <td>0.251320</td>\n",
       "      <td>0.169948</td>\n",
       "      <td>0.310134</td>\n",
       "      <td>0.363714</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>5</td>\n",
       "      <td>0.449654</td>\n",
       "      <td>0.393005</td>\n",
       "      <td>4.141575</td>\n",
       "      <td>-0.783133</td>\n",
       "      <td>-2.557616</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    lat  lon  month  year       sst      t300        ua        va      nino  \\\n",
       "0 -55.0  0.0      1     1  0.346436 -0.244890 -1.680264 -0.489486 -0.261025   \n",
       "1 -55.0  0.0      1     2 -0.493941 -0.165055  2.115858  0.994749 -0.512528   \n",
       "2 -55.0  0.0      1     3 -0.018142 -0.261186 -1.463467  1.306921 -0.169389   \n",
       "3 -55.0  0.0      1     4  1.050851  0.251320  0.169948  0.310134  0.363714   \n",
       "4 -55.0  0.0      1     5  0.449654  0.393005  4.141575 -0.783133 -2.557616   \n",
       "\n",
       "    mode  \n",
       "0  60001  \n",
       "1  60001  \n",
       "2  60001  \n",
       "3  60001  \n",
       "4  60001  "
      ]
     },
     "execution_count": 538,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "CMIPdf.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 539,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>lat</th>\n",
       "      <th>lon</th>\n",
       "      <th>month</th>\n",
       "      <th>year</th>\n",
       "      <th>sst</th>\n",
       "      <th>t300</th>\n",
       "      <th>ua</th>\n",
       "      <th>va</th>\n",
       "      <th>nino</th>\n",
       "      <th>mode</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>1</td>\n",
       "      <td>0.346436</td>\n",
       "      <td>-0.244890</td>\n",
       "      <td>-1.680264</td>\n",
       "      <td>-0.489486</td>\n",
       "      <td>-0.261025</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>-0.493941</td>\n",
       "      <td>-0.165055</td>\n",
       "      <td>2.115858</td>\n",
       "      <td>0.994749</td>\n",
       "      <td>-0.512528</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>3</td>\n",
       "      <td>-0.018142</td>\n",
       "      <td>-0.261186</td>\n",
       "      <td>-1.463467</td>\n",
       "      <td>1.306921</td>\n",
       "      <td>-0.169389</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>4</td>\n",
       "      <td>1.050851</td>\n",
       "      <td>0.251320</td>\n",
       "      <td>0.169948</td>\n",
       "      <td>0.310134</td>\n",
       "      <td>0.363714</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>5</td>\n",
       "      <td>0.449654</td>\n",
       "      <td>0.393005</td>\n",
       "      <td>4.141575</td>\n",
       "      <td>-0.783133</td>\n",
       "      <td>-2.557616</td>\n",
       "      <td>60001</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    lat  lon  month  year       sst      t300        ua        va      nino  \\\n",
       "0 -55.0  0.0      1     1  0.346436 -0.244890 -1.680264 -0.489486 -0.261025   \n",
       "1 -55.0  0.0      1     2 -0.493941 -0.165055  2.115858  0.994749 -0.512528   \n",
       "2 -55.0  0.0      1     3 -0.018142 -0.261186 -1.463467  1.306921 -0.169389   \n",
       "3 -55.0  0.0      1     4  1.050851  0.251320  0.169948  0.310134  0.363714   \n",
       "4 -55.0  0.0      1     5  0.449654  0.393005  4.141575 -0.783133 -2.557616   \n",
       "\n",
       "    mode  \n",
       "0  60001  \n",
       "1  60001  \n",
       "2  60001  \n",
       "3  60001  \n",
       "4  60001  "
      ]
     },
     "execution_count": 539,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def transyear(x):#因为遍历规则，不能对X比较大小 报错ambiguous\n",
    "    temp=(x<2266)*((x-1)%151+1)+(x>2265)*((x-1-2265)%140+1)#年份的顺序，计数从1开始\n",
    "    return temp\n",
    "CMIPdf['year']=CMIPdf['year'].apply(transyear)\n",
    "CMIPdf.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 557,
   "metadata": {},
   "outputs": [],
   "source": [
    "#CMIPdf=CMIPdf.drop('day',axis=1)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 558,
   "metadata": {},
   "outputs": [],
   "source": [
    "CMIPdf['time']=CMIPdf.year*12+CMIPdf.month-12"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 542,
   "metadata": {},
   "outputs": [],
   "source": [
    "#这一步之后可转换为Dataset\n",
    "#CMIPdf = CMIPdf.set_index(['lat', 'lon','month','year','mode'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 545,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "datetime.datetime(2000, 1, 1, 0, 0)"
      ]
     },
     "execution_count": 545,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#datetime.datetime(year=2000,month=1,day=1)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 560,
   "metadata": {},
   "outputs": [],
   "source": [
    "c=nc.Dataset('../tcdata/enso_round1_train_20210201/SODA_train.nc')\n",
    "C= xr.open_dataset(xr.backends.NetCDF4DataStore(c))\n",
    "d=nc.Dataset('../tcdata/enso_round1_train_20210201/SODA_label.nc')\n",
    "D= xr.open_dataset(xr.backends.NetCDF4DataStore(d))\n",
    "SODA=C\n",
    "SODA['nino']=(('year','month'),D.nino)\n",
    "SODA=SODA.drop_sel(month=np.arange(13,37))\n",
    "SODAdf=SODA.to_dataframe()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 564,
   "metadata": {},
   "outputs": [],
   "source": [
    "SODAdf=SODAdf.reset_index()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 565,
   "metadata": {},
   "outputs": [],
   "source": [
    "SODAdf['mode']=10000"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 566,
   "metadata": {},
   "outputs": [],
   "source": [
    "SODAdf['time']=SODAdf.year*12+SODAdf.month-12"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 568,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>lat</th>\n",
       "      <th>lon</th>\n",
       "      <th>month</th>\n",
       "      <th>year</th>\n",
       "      <th>sst</th>\n",
       "      <th>t300</th>\n",
       "      <th>ua</th>\n",
       "      <th>va</th>\n",
       "      <th>nino</th>\n",
       "      <th>mode</th>\n",
       "      <th>time</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>1</td>\n",
       "      <td>1.861851</td>\n",
       "      <td>0.374280</td>\n",
       "      <td>0.429292</td>\n",
       "      <td>0.087189</td>\n",
       "      <td>-0.407207</td>\n",
       "      <td>10000</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>-0.272264</td>\n",
       "      <td>0.062039</td>\n",
       "      <td>2.033018</td>\n",
       "      <td>-0.978357</td>\n",
       "      <td>0.066972</td>\n",
       "      <td>10000</td>\n",
       "      <td>13</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>3</td>\n",
       "      <td>0.029107</td>\n",
       "      <td>0.023624</td>\n",
       "      <td>0.014763</td>\n",
       "      <td>-0.337003</td>\n",
       "      <td>-0.732018</td>\n",
       "      <td>10000</td>\n",
       "      <td>25</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>4</td>\n",
       "      <td>0.116086</td>\n",
       "      <td>0.002191</td>\n",
       "      <td>-0.779131</td>\n",
       "      <td>0.283343</td>\n",
       "      <td>-0.259308</td>\n",
       "      <td>10000</td>\n",
       "      <td>37</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>-55.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>1</td>\n",
       "      <td>5</td>\n",
       "      <td>-0.303765</td>\n",
       "      <td>-0.017604</td>\n",
       "      <td>0.718747</td>\n",
       "      <td>0.432904</td>\n",
       "      <td>-0.123334</td>\n",
       "      <td>10000</td>\n",
       "      <td>49</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    lat  lon  month  year       sst      t300        ua        va      nino  \\\n",
       "0 -55.0  0.0      1     1  1.861851  0.374280  0.429292  0.087189 -0.407207   \n",
       "1 -55.0  0.0      1     2 -0.272264  0.062039  2.033018 -0.978357  0.066972   \n",
       "2 -55.0  0.0      1     3  0.029107  0.023624  0.014763 -0.337003 -0.732018   \n",
       "3 -55.0  0.0      1     4  0.116086  0.002191 -0.779131  0.283343 -0.259308   \n",
       "4 -55.0  0.0      1     5 -0.303765 -0.017604  0.718747  0.432904 -0.123334   \n",
       "\n",
       "    mode  time  \n",
       "0  10000     1  \n",
       "1  10000    13  \n",
       "2  10000    25  \n",
       "3  10000    37  \n",
       "4  10000    49  "
      ]
     },
     "execution_count": 568,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "SODAdf.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 570,
   "metadata": {},
   "outputs": [],
   "source": [
    "data=pd.concat([CMIPdf, SODAdf])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 572,
   "metadata": {},
   "outputs": [],
   "source": [
    "data_reindex=data.set_index(['lat', 'lon','month','year','mode'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 576,
   "metadata": {},
   "outputs": [],
   "source": [
    "data_set=xr.Dataset.from_dataframe(data_reindex)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 577,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div><svg style=\"position: absolute; width: 0; height: 0; overflow: hidden\">\n",
       "<defs>\n",
       "<symbol id=\"icon-database\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M16 0c-8.837 0-16 2.239-16 5v4c0 2.761 7.163 5 16 5s16-2.239 16-5v-4c0-2.761-7.163-5-16-5z\"></path>\n",
       "<path d=\"M16 17c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "<path d=\"M16 26c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "</symbol>\n",
       "<symbol id=\"icon-file-text2\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M28.681 7.159c-0.694-0.947-1.662-2.053-2.724-3.116s-2.169-2.030-3.116-2.724c-1.612-1.182-2.393-1.319-2.841-1.319h-15.5c-1.378 0-2.5 1.121-2.5 2.5v27c0 1.378 1.122 2.5 2.5 2.5h23c1.378 0 2.5-1.122 2.5-2.5v-19.5c0-0.448-0.137-1.23-1.319-2.841zM24.543 5.457c0.959 0.959 1.712 1.825 2.268 2.543h-4.811v-4.811c0.718 0.556 1.584 1.309 2.543 2.268zM28 29.5c0 0.271-0.229 0.5-0.5 0.5h-23c-0.271 0-0.5-0.229-0.5-0.5v-27c0-0.271 0.229-0.5 0.5-0.5 0 0 15.499-0 15.5 0v7c0 0.552 0.448 1 1 1h7v19.5z\"></path>\n",
       "<path d=\"M23 26h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 22h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 18h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "</symbol>\n",
       "</defs>\n",
       "</svg>\n",
       "<style>/* CSS stylesheet for displaying xarray objects in jupyterlab.\n",
       " *\n",
       " */\n",
       "\n",
       ":root {\n",
       "  --xr-font-color0: var(--jp-content-font-color0, rgba(0, 0, 0, 1));\n",
       "  --xr-font-color2: var(--jp-content-font-color2, rgba(0, 0, 0, 0.54));\n",
       "  --xr-font-color3: var(--jp-content-font-color3, rgba(0, 0, 0, 0.38));\n",
       "  --xr-border-color: var(--jp-border-color2, #e0e0e0);\n",
       "  --xr-disabled-color: var(--jp-layout-color3, #bdbdbd);\n",
       "  --xr-background-color: var(--jp-layout-color0, white);\n",
       "  --xr-background-color-row-even: var(--jp-layout-color1, white);\n",
       "  --xr-background-color-row-odd: var(--jp-layout-color2, #eeeeee);\n",
       "}\n",
       "\n",
       "html[theme=dark],\n",
       "body.vscode-dark {\n",
       "  --xr-font-color0: rgba(255, 255, 255, 1);\n",
       "  --xr-font-color2: rgba(255, 255, 255, 0.54);\n",
       "  --xr-font-color3: rgba(255, 255, 255, 0.38);\n",
       "  --xr-border-color: #1F1F1F;\n",
       "  --xr-disabled-color: #515151;\n",
       "  --xr-background-color: #111111;\n",
       "  --xr-background-color-row-even: #111111;\n",
       "  --xr-background-color-row-odd: #313131;\n",
       "}\n",
       "\n",
       ".xr-wrap {\n",
       "  display: block;\n",
       "  min-width: 300px;\n",
       "  max-width: 700px;\n",
       "}\n",
       "\n",
       ".xr-text-repr-fallback {\n",
       "  /* fallback to plain text repr when CSS is not injected (untrusted notebook) */\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-header {\n",
       "  padding-top: 6px;\n",
       "  padding-bottom: 6px;\n",
       "  margin-bottom: 4px;\n",
       "  border-bottom: solid 1px var(--xr-border-color);\n",
       "}\n",
       "\n",
       ".xr-header > div,\n",
       ".xr-header > ul {\n",
       "  display: inline;\n",
       "  margin-top: 0;\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-obj-type,\n",
       ".xr-array-name {\n",
       "  margin-left: 2px;\n",
       "  margin-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-obj-type {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-sections {\n",
       "  padding-left: 0 !important;\n",
       "  display: grid;\n",
       "  grid-template-columns: 150px auto auto 1fr 20px 20px;\n",
       "}\n",
       "\n",
       ".xr-section-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-section-item input {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-item input + label {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label {\n",
       "  cursor: pointer;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label:hover {\n",
       "  color: var(--xr-font-color0);\n",
       "}\n",
       "\n",
       ".xr-section-summary {\n",
       "  grid-column: 1;\n",
       "  color: var(--xr-font-color2);\n",
       "  font-weight: 500;\n",
       "}\n",
       "\n",
       ".xr-section-summary > span {\n",
       "  display: inline-block;\n",
       "  padding-left: 0.5em;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in + label:before {\n",
       "  display: inline-block;\n",
       "  content: '►';\n",
       "  font-size: 11px;\n",
       "  width: 15px;\n",
       "  text-align: center;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label:before {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label:before {\n",
       "  content: '▼';\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label > span {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-summary,\n",
       ".xr-section-inline-details {\n",
       "  padding-top: 4px;\n",
       "  padding-bottom: 4px;\n",
       "}\n",
       "\n",
       ".xr-section-inline-details {\n",
       "  grid-column: 2 / -1;\n",
       "}\n",
       "\n",
       ".xr-section-details {\n",
       "  display: none;\n",
       "  grid-column: 1 / -1;\n",
       "  margin-bottom: 5px;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked ~ .xr-section-details {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-array-wrap {\n",
       "  grid-column: 1 / -1;\n",
       "  display: grid;\n",
       "  grid-template-columns: 20px auto;\n",
       "}\n",
       "\n",
       ".xr-array-wrap > label {\n",
       "  grid-column: 1;\n",
       "  vertical-align: top;\n",
       "}\n",
       "\n",
       ".xr-preview {\n",
       "  color: var(--xr-font-color3);\n",
       "}\n",
       "\n",
       ".xr-array-preview,\n",
       ".xr-array-data {\n",
       "  padding: 0 5px !important;\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-array-data,\n",
       ".xr-array-in:checked ~ .xr-array-preview {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-array-in:checked ~ .xr-array-data,\n",
       ".xr-array-preview {\n",
       "  display: inline-block;\n",
       "}\n",
       "\n",
       ".xr-dim-list {\n",
       "  display: inline-block !important;\n",
       "  list-style: none;\n",
       "  padding: 0 !important;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list li {\n",
       "  display: inline-block;\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list:before {\n",
       "  content: '(';\n",
       "}\n",
       "\n",
       ".xr-dim-list:after {\n",
       "  content: ')';\n",
       "}\n",
       "\n",
       ".xr-dim-list li:not(:last-child):after {\n",
       "  content: ',';\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-has-index {\n",
       "  font-weight: bold;\n",
       "}\n",
       "\n",
       ".xr-var-list,\n",
       ".xr-var-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-var-item > div,\n",
       ".xr-var-item label,\n",
       ".xr-var-item > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-even);\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-var-item > .xr-var-name:hover span {\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-var-list > li:nth-child(odd) > div,\n",
       ".xr-var-list > li:nth-child(odd) > label,\n",
       ".xr-var-list > li:nth-child(odd) > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-odd);\n",
       "}\n",
       "\n",
       ".xr-var-name {\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-var-dims {\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-var-dtype {\n",
       "  grid-column: 3;\n",
       "  text-align: right;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-var-preview {\n",
       "  grid-column: 4;\n",
       "}\n",
       "\n",
       ".xr-var-name,\n",
       ".xr-var-dims,\n",
       ".xr-var-dtype,\n",
       ".xr-preview,\n",
       ".xr-attrs dt {\n",
       "  white-space: nowrap;\n",
       "  overflow: hidden;\n",
       "  text-overflow: ellipsis;\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-var-name:hover,\n",
       ".xr-var-dims:hover,\n",
       ".xr-var-dtype:hover,\n",
       ".xr-attrs dt:hover {\n",
       "  overflow: visible;\n",
       "  width: auto;\n",
       "  z-index: 1;\n",
       "}\n",
       "\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  display: none;\n",
       "  background-color: var(--xr-background-color) !important;\n",
       "  padding-bottom: 5px !important;\n",
       "}\n",
       "\n",
       ".xr-var-attrs-in:checked ~ .xr-var-attrs,\n",
       ".xr-var-data-in:checked ~ .xr-var-data {\n",
       "  display: block;\n",
       "}\n",
       "\n",
       ".xr-var-data > table {\n",
       "  float: right;\n",
       "}\n",
       "\n",
       ".xr-var-name span,\n",
       ".xr-var-data,\n",
       ".xr-attrs {\n",
       "  padding-left: 25px !important;\n",
       "}\n",
       "\n",
       ".xr-attrs,\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  grid-column: 1 / -1;\n",
       "}\n",
       "\n",
       "dl.xr-attrs {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  display: grid;\n",
       "  grid-template-columns: 125px auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt, dd {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  float: left;\n",
       "  padding-right: 10px;\n",
       "  width: auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt {\n",
       "  font-weight: normal;\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-attrs dt:hover span {\n",
       "  display: inline-block;\n",
       "  background: var(--xr-background-color);\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-attrs dd {\n",
       "  grid-column: 2;\n",
       "  white-space: pre-wrap;\n",
       "  word-break: break-all;\n",
       "}\n",
       "\n",
       ".xr-icon-database,\n",
       ".xr-icon-file-text2 {\n",
       "  display: inline-block;\n",
       "  vertical-align: middle;\n",
       "  width: 1em;\n",
       "  height: 1.5em !important;\n",
       "  stroke-width: 0;\n",
       "  stroke: currentColor;\n",
       "  fill: currentColor;\n",
       "}\n",
       "</style><pre class='xr-text-repr-fallback'>&lt;xarray.Dataset&gt;\n",
       "Dimensions:  (lat: 24, lon: 72, mode: 33, month: 12, year: 151)\n",
       "Coordinates:\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "  * month    (month) int64 1 2 3 4 5 6 7 8 9 10 11 12\n",
       "  * year     (year) int64 1 2 3 4 5 6 7 8 9 ... 144 145 146 147 148 149 150 151\n",
       "  * mode     (mode) int64 10000 50001 50002 50003 ... 60012 60013 60014 60015\n",
       "Data variables:\n",
       "    index    (lat, lon, month, year, mode) float64 nan 2.265e+03 ... 9.632e+07\n",
       "    sst      (lat, lon, month, year, mode) float64 1.862 -0.3493 ... 0.252\n",
       "    t300     (lat, lon, month, year, mode) float64 0.3743 -0.7049 ... 0.2332\n",
       "    ua       (lat, lon, month, year, mode) float64 0.4293 -2.984 ... -1.701\n",
       "    va       (lat, lon, month, year, mode) float64 0.08719 0.07952 ... 2.318\n",
       "    nino     (lat, lon, month, year, mode) float64 -0.4072 -1.91 ... -0.5696\n",
       "    time     (lat, lon, month, year, mode) float64 1.0 1.0 ... 1.812e+03</pre><div class='xr-wrap' hidden><div class='xr-header'><div class='xr-obj-type'>xarray.Dataset</div></div><ul class='xr-sections'><li class='xr-section-item'><input id='section-5ab0ee52-dd41-46dc-b4a3-1712bb8fc987' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-5ab0ee52-dd41-46dc-b4a3-1712bb8fc987' class='xr-section-summary'  title='Expand/collapse section'>Dimensions:</label><div class='xr-section-inline-details'><ul class='xr-dim-list'><li><span class='xr-has-index'>lat</span>: 24</li><li><span class='xr-has-index'>lon</span>: 72</li><li><span class='xr-has-index'>mode</span>: 33</li><li><span class='xr-has-index'>month</span>: 12</li><li><span class='xr-has-index'>year</span>: 151</li></ul></div><div class='xr-section-details'></div></li><li class='xr-section-item'><input id='section-e478274d-d1fb-496a-9752-e84d018a6191' class='xr-section-summary-in' type='checkbox'  checked><label for='section-e478274d-d1fb-496a-9752-e84d018a6191' class='xr-section-summary' >Coordinates: <span>(5)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lat</span></div><div class='xr-var-dims'>(lat)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-55.0 -50.0 -45.0 ... 55.0 60.0</div><input id='attrs-7969050e-d87a-4772-95c8-860c0d9b2d14' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-7969050e-d87a-4772-95c8-860c0d9b2d14' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-c6f2939c-f0be-4ba3-a0e5-d202fa7c4fbe' class='xr-var-data-in' type='checkbox'><label for='data-c6f2939c-f0be-4ba3-a0e5-d202fa7c4fbe' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([-55., -50., -45., -40., -35., -30., -25., -20., -15., -10.,  -5.,   0.,\n",
       "         5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,  60.])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lon</span></div><div class='xr-var-dims'>(lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.0 5.0 10.0 ... 345.0 350.0 355.0</div><input id='attrs-42e5e6d4-0e83-49b2-9370-7989ac64445a' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-42e5e6d4-0e83-49b2-9370-7989ac64445a' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-84e905d9-ae92-4b4a-9915-03a135814221' class='xr-var-data-in' type='checkbox'><label for='data-84e905d9-ae92-4b4a-9915-03a135814221' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  0.,   5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,\n",
       "        60.,  65.,  70.,  75.,  80.,  85.,  90.,  95., 100., 105., 110., 115.,\n",
       "       120., 125., 130., 135., 140., 145., 150., 155., 160., 165., 170., 175.,\n",
       "       180., 185., 190., 195., 200., 205., 210., 215., 220., 225., 230., 235.,\n",
       "       240., 245., 250., 255., 260., 265., 270., 275., 280., 285., 290., 295.,\n",
       "       300., 305., 310., 315., 320., 325., 330., 335., 340., 345., 350., 355.])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>month</span></div><div class='xr-var-dims'>(month)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 7 8 9 10 11 12</div><input id='attrs-c2af7eef-c42b-4228-90e7-3e15b73e6bf0' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-c2af7eef-c42b-4228-90e7-3e15b73e6bf0' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-469a5f27-337c-4703-8255-d2ad00c8c1f4' class='xr-var-data-in' type='checkbox'><label for='data-469a5f27-337c-4703-8255-d2ad00c8c1f4' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>year</span></div><div class='xr-var-dims'>(year)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 ... 147 148 149 150 151</div><input id='attrs-b57439ac-95d4-43dd-b342-8502a4f184c5' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-b57439ac-95d4-43dd-b342-8502a4f184c5' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-4ce57c77-380d-49f4-be2d-3781342c53cf' class='xr-var-data-in' type='checkbox'><label for='data-4ce57c77-380d-49f4-be2d-3781342c53cf' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  1,   2,   3,   4,   5,   6,   7,   8,   9,  10,  11,  12,  13,  14,\n",
       "        15,  16,  17,  18,  19,  20,  21,  22,  23,  24,  25,  26,  27,  28,\n",
       "        29,  30,  31,  32,  33,  34,  35,  36,  37,  38,  39,  40,  41,  42,\n",
       "        43,  44,  45,  46,  47,  48,  49,  50,  51,  52,  53,  54,  55,  56,\n",
       "        57,  58,  59,  60,  61,  62,  63,  64,  65,  66,  67,  68,  69,  70,\n",
       "        71,  72,  73,  74,  75,  76,  77,  78,  79,  80,  81,  82,  83,  84,\n",
       "        85,  86,  87,  88,  89,  90,  91,  92,  93,  94,  95,  96,  97,  98,\n",
       "        99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112,\n",
       "       113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126,\n",
       "       127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140,\n",
       "       141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>mode</span></div><div class='xr-var-dims'>(mode)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>10000 50001 50002 ... 60014 60015</div><input id='attrs-11d671fc-4ae3-4c06-8689-17413a612c53' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-11d671fc-4ae3-4c06-8689-17413a612c53' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-8d6d9381-37cb-4496-99a7-f85d70da4086' class='xr-var-data-in' type='checkbox'><label for='data-8d6d9381-37cb-4496-99a7-f85d70da4086' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([10000, 50001, 50002, 50003, 50004, 50005, 50006, 50007, 50008, 50009,\n",
       "       50010, 50011, 50012, 50013, 50014, 50015, 50016, 50017, 60001, 60002,\n",
       "       60003, 60004, 60005, 60006, 60007, 60008, 60009, 60010, 60011, 60012,\n",
       "       60013, 60014, 60015])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-83cabd8b-84bf-45a4-b3ce-c1e03108f77d' class='xr-section-summary-in' type='checkbox'  checked><label for='section-83cabd8b-84bf-45a4-b3ce-c1e03108f77d' class='xr-section-summary' >Data variables: <span>(7)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span>index</span></div><div class='xr-var-dims'>(lat, lon, month, year, mode)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>nan 2.265e+03 ... 9.632e+07</div><input id='attrs-a29c805e-5592-4278-9c93-44a4ec31ede9' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-a29c805e-5592-4278-9c93-44a4ec31ede9' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-b3ead36c-65f2-4100-bf3a-e4aea1bcafd3' class='xr-var-data-in' type='checkbox'><label for='data-b3ead36c-65f2-4100-bf3a-e4aea1bcafd3' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[[          nan, 2.2650000e+03, 2.4050000e+03, ...,\n",
       "           1.8120000e+03, 1.9630000e+03, 2.1140000e+03],\n",
       "          [          nan, 2.2660000e+03, 2.4060000e+03, ...,\n",
       "           1.8130000e+03, 1.9640000e+03, 2.1150000e+03],\n",
       "          [          nan, 2.2670000e+03, 2.4070000e+03, ...,\n",
       "           1.8140000e+03, 1.9650000e+03, 2.1160000e+03],\n",
       "          ...,\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           1.9600000e+03, 2.1110000e+03, 2.2620000e+03],\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           1.9610000e+03, 2.1120000e+03, 2.2630000e+03],\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           1.9620000e+03, 2.1130000e+03, 2.2640000e+03]],\n",
       "\n",
       "         [[          nan, 6.9100000e+03, 7.0500000e+03, ...,\n",
       "           6.4570000e+03, 6.6080000e+03, 6.7590000e+03],\n",
       "          [          nan, 6.9110000e+03, 7.0510000e+03, ...,\n",
       "           6.4580000e+03, 6.6090000e+03, 6.7600000e+03],\n",
       "          [          nan, 6.9120000e+03, 7.0520000e+03, ...,\n",
       "           6.4590000e+03, 6.6100000e+03, 6.7610000e+03],\n",
       "...\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           9.6311390e+07, 9.6311541e+07, 9.6311692e+07],\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           9.6311391e+07, 9.6311542e+07, 9.6311693e+07],\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           9.6311392e+07, 9.6311543e+07, 9.6311694e+07]],\n",
       "\n",
       "         [[          nan, 9.6316340e+07, 9.6316480e+07, ...,\n",
       "           9.6315887e+07, 9.6316038e+07, 9.6316189e+07],\n",
       "          [          nan, 9.6316341e+07, 9.6316481e+07, ...,\n",
       "           9.6315888e+07, 9.6316039e+07, 9.6316190e+07],\n",
       "          [          nan, 9.6316342e+07, 9.6316482e+07, ...,\n",
       "           9.6315889e+07, 9.6316040e+07, 9.6316191e+07],\n",
       "          ...,\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           9.6316035e+07, 9.6316186e+07, 9.6316337e+07],\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           9.6316036e+07, 9.6316187e+07, 9.6316338e+07],\n",
       "          [          nan,           nan,           nan, ...,\n",
       "           9.6316037e+07, 9.6316188e+07, 9.6316339e+07]]]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>sst</span></div><div class='xr-var-dims'>(lat, lon, month, year, mode)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>1.862 -0.3493 ... -0.09875 0.252</div><input id='attrs-ea687196-6dd0-442d-bcc4-8ea68bef9c02' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-ea687196-6dd0-442d-bcc4-8ea68bef9c02' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-3748fe7a-248b-4ab4-b88f-f3105f7e30f7' class='xr-var-data-in' type='checkbox'><label for='data-3748fe7a-248b-4ab4-b88f-f3105f7e30f7' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[[ 1.86185086e+00, -3.49271983e-01, -5.59290946e-01, ...,\n",
       "           -9.24604237e-01,  3.11713696e-01, -4.74924207e-01],\n",
       "          [-2.72263676e-01, -1.11764359e+00,  6.50212228e-01, ...,\n",
       "            1.12225056e-01,  7.33960629e-01,  4.21124339e-01],\n",
       "          [ 2.91070752e-02, -8.56962383e-01, -4.97694761e-02, ...,\n",
       "           -5.96231341e-01,  4.27625895e-01,  4.34679747e-01],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "           -6.27900124e-01,  9.89589691e-02,  5.23797750e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "           -2.77597070e-01,  1.63841009e-01,  3.56218934e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            5.08040190e-02, -4.59757924e-01,  3.62793207e-01]],\n",
       "\n",
       "         [[ 1.26678228e+00,  5.86477444e-02, -2.12527186e-01, ...,\n",
       "           -6.00532651e-01,  4.15128708e-01, -3.38467956e-01],\n",
       "          [ 1.24272145e-01, -1.13217866e+00,  4.30234045e-01, ...,\n",
       "            8.87982845e-02,  6.46081924e-01,  6.63015127e-01],\n",
       "          [ 4.56265628e-01, -4.43793654e-01, -1.95254236e-01, ...,\n",
       "           -1.67360783e-01,  3.65773201e-01,  1.09977245e-01],\n",
       "...\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            6.53336525e-01, -1.55879974e-01,  3.03862572e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            5.84268570e-02, -1.19050980e-01,  1.09602928e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            1.45031929e-01, -1.05566978e-01,  2.25828171e-01]],\n",
       "\n",
       "         [[ 5.40099084e-01, -4.54719156e-01, -1.20070875e-01, ...,\n",
       "           -3.33290100e-01,  4.45947647e-02, -1.56202316e-01],\n",
       "          [-8.65866780e-01, -7.97950387e-01,  3.59654985e-02, ...,\n",
       "            5.15108109e-02, -2.59470940e-01, -8.77780914e-02],\n",
       "          [ 5.44332325e-01, -4.78309244e-01, -1.04118299e+00, ...,\n",
       "           -1.12032890e-01, -4.43719864e-01, -6.66777611e-01],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            4.22628403e-01, -2.16940880e-01,  3.96060944e-03],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            1.48679733e-01, -2.95190811e-01,  3.64673615e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            4.60297585e-01, -9.87472534e-02,  2.51951218e-01]]]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>t300</span></div><div class='xr-var-dims'>(lat, lon, month, year, mode)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.3743 -0.7049 ... -0.08974 0.2332</div><input id='attrs-b118367e-1e49-48d0-ad90-4beaf5168c2c' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-b118367e-1e49-48d0-ad90-4beaf5168c2c' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-08f4deb5-132f-4450-87ba-062f434973aa' class='xr-var-data-in' type='checkbox'><label for='data-08f4deb5-132f-4450-87ba-062f434973aa' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[[ 3.74279588e-01, -7.04940915e-01, -2.82149523e-01, ...,\n",
       "           -3.00178289e-01,  2.05827594e-01, -4.36790049e-01],\n",
       "          [ 6.20391332e-02, -4.00589108e-01, -4.78355549e-02, ...,\n",
       "           -4.30333503e-02,  4.06211257e-01,  8.43089819e-02],\n",
       "          [ 2.36240607e-02, -3.52859616e-01, -2.39402931e-02, ...,\n",
       "           -1.71419919e-01,  1.86344847e-01,  2.07180992e-01],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "           -4.47960123e-02,  1.38564959e-01,  3.55711251e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            3.91419455e-02,  2.06331000e-01,  4.09069002e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            1.25217155e-01, -1.78777307e-01,  3.73114377e-01]],\n",
       "\n",
       "         [[ 3.21986049e-01, -6.60583079e-01, -2.65921652e-01, ...,\n",
       "           -2.36465976e-01,  1.98196217e-01, -3.42619866e-01],\n",
       "          [ 4.96488251e-02, -3.93004954e-01, -5.06811626e-02, ...,\n",
       "           -9.15321633e-02,  3.59772325e-01,  1.49064809e-01],\n",
       "          [ 1.04728965e-02, -3.44848216e-01, -4.25024517e-02, ...,\n",
       "           -1.25054523e-01,  1.77255467e-01,  1.12111583e-01],\n",
       "...\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            5.59438109e-01, -1.84236571e-01,  3.02480608e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            1.77701026e-01, -1.33429945e-01,  9.99939144e-02],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            2.26453289e-01, -1.37978643e-01,  2.19319254e-01]],\n",
       "\n",
       "         [[ 3.40770572e-01, -4.76387292e-01, -1.76126122e-01, ...,\n",
       "           -3.37953597e-01,  6.28788173e-02, -1.31263062e-01],\n",
       "          [-4.08036262e-01, -7.46650934e-01, -4.27948199e-02, ...,\n",
       "            4.43915352e-02, -2.54005462e-01, -6.90494999e-02],\n",
       "          [ 5.06483674e-01, -4.65919763e-01, -1.48080468e-01, ...,\n",
       "           -1.17034487e-01, -4.43292052e-01, -6.50649011e-01],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            4.27112520e-01, -2.23397091e-01,  1.59056708e-02],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            1.83998272e-01, -3.05224210e-01,  2.99689710e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            4.64207828e-01, -8.97353217e-02,  2.33204633e-01]]]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>ua</span></div><div class='xr-var-dims'>(lat, lon, month, year, mode)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.4293 -2.984 ... 1.683 -1.701</div><input id='attrs-dd5d3c86-3690-4926-9dbe-98ed573cb892' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-dd5d3c86-3690-4926-9dbe-98ed573cb892' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-674e8ac4-d02a-4400-97e7-433ecd660133' class='xr-var-data-in' type='checkbox'><label for='data-674e8ac4-d02a-4400-97e7-433ecd660133' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[[ 4.29292202e-01, -2.98401380e+00, -8.74612331e-01, ...,\n",
       "                       nan,  2.50926828e+00, -2.96184349e+00],\n",
       "          [ 2.03301811e+00,  6.72957420e-01, -5.39154053e-01, ...,\n",
       "            1.51357579e+00, -2.04294538e+00, -4.35545921e+00],\n",
       "          [ 1.47628784e-02,  1.03928900e+00, -1.89796114e+00, ...,\n",
       "                       nan,  1.76662970e+00, -8.80071640e-01],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan,  2.96127796e-01,  1.26263618e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan,  8.94975662e-03,  9.13053513e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan,  1.18965578e+00,  1.49412441e+00]],\n",
       "\n",
       "         [[ 1.04252148e+00, -1.00822830e+00, -6.49953890e+00, ...,\n",
       "                       nan,  4.53596115e-01, -2.23866463e-01],\n",
       "          [ 6.34977818e-01, -9.77067947e-02, -2.00872707e+00, ...,\n",
       "                       nan, -5.76143265e-02, -2.72674656e+00],\n",
       "          [ 2.32324600e-01,  8.39175701e-01,  1.60554028e+00, ...,\n",
       "                       nan, -2.54999161e-01,  5.81995010e-01],\n",
       "...\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            3.44768667e+00, -2.04552794e+00,  3.65964031e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan,  2.52826309e+00, -2.29710698e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan,  2.13245678e+00, -3.89203286e+00]],\n",
       "\n",
       "         [[ 3.03591609e+00, -9.62917447e-01, -3.15412951e+00, ...,\n",
       "                       nan,  4.34681511e+00, -5.59778214e+00],\n",
       "          [-5.80912542e+00,  1.98055220e+00, -1.41543496e+00, ...,\n",
       "                       nan, -2.74677157e+00, -1.31738496e+00],\n",
       "          [ 4.94480896e+00, -2.56133175e+00, -5.16086388e+00, ...,\n",
       "            1.20083570e+00,  3.76193285e-01, -2.91971970e+00],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "           -2.44567060e+00, -4.70701504e+00,  2.40291667e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            2.87650514e+00, -4.75465155e+00, -1.99859476e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "           -5.72856855e+00,  1.68271947e+00, -1.70148802e+00]]]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>va</span></div><div class='xr-var-dims'>(lat, lon, month, year, mode)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.08719 0.07952 ... 5.249 2.318</div><input id='attrs-f80a8ffb-acec-4371-8dbe-5f28affb85b8' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-f80a8ffb-acec-4371-8dbe-5f28affb85b8' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-a6351e1a-0b4c-4668-9a72-0e9f5577679e' class='xr-var-data-in' type='checkbox'><label for='data-a6351e1a-0b4c-4668-9a72-0e9f5577679e' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[[ 8.71891379e-02,  7.95152187e-02,  5.32869101e-02, ...,\n",
       "                       nan, -6.99225187e-01,  9.71282423e-01],\n",
       "          [-9.78357315e-01,  1.26036263e+00, -1.09415817e+00, ...,\n",
       "            7.85947084e-01,  2.80004549e+00,  1.74421000e+00],\n",
       "          [-3.37002784e-01, -6.93388939e-01,  1.42763448e+00, ...,\n",
       "                       nan, -7.28814602e-01, -4.44452763e-01],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan, -1.79835975e+00, -3.83331442e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan, -9.45754170e-01,  3.39345288e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan, -1.28428149e+00, -1.25352716e+00]],\n",
       "\n",
       "         [[ 1.33735359e-01,  1.40486526e+00,  3.13494897e+00, ...,\n",
       "                       nan,  1.14533648e-01, -2.24468184e+00],\n",
       "          [-2.38034010e-01,  1.78673577e+00,  2.28734374e-01, ...,\n",
       "                       nan,  4.84056294e-01,  6.02204561e-01],\n",
       "          [-1.35312498e-01, -1.69063115e+00, -5.97966552e-01, ...,\n",
       "                       nan,  3.40929031e-02, -1.26215661e+00],\n",
       "...\n",
       "          [            nan,             nan,             nan, ...,\n",
       "           -5.04572105e+00,  1.79858017e+00, -1.49702883e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan,  1.69155955e-01, -1.63503373e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "                       nan,  5.38094139e+00,  8.41167688e-01]],\n",
       "\n",
       "         [[-1.56330228e-01, -3.92228174e+00,  2.20405912e+00, ...,\n",
       "                       nan, -3.33259153e+00, -2.91432858e+00],\n",
       "          [-7.38463759e-01,  1.77917361e-01,  2.95592642e+00, ...,\n",
       "                       nan, -5.63371754e+00,  8.73346329e-02],\n",
       "          [ 7.19276905e-01,  2.23514366e+00,  1.76140165e+00, ...,\n",
       "            3.33792424e+00,  8.03502083e-01, -3.73463631e+00],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "           -2.31013417e+00,  1.86122417e+00,  1.88401699e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            7.06686497e-01, -3.26596904e+00,  3.43192434e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            5.94424343e+00,  5.24936247e+00,  2.31778765e+00]]]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>nino</span></div><div class='xr-var-dims'>(lat, lon, month, year, mode)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-0.4072 -1.91 ... 0.1413 -0.5696</div><input id='attrs-adc92b15-e72b-44b6-886a-05176a755834' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-adc92b15-e72b-44b6-886a-05176a755834' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-66b1edb9-f427-4849-8ae9-4cd4fcd5fb0a' class='xr-var-data-in' type='checkbox'><label for='data-66b1edb9-f427-4849-8ae9-4cd4fcd5fb0a' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[[-4.07207012e-01, -1.91032517e+00,  6.13110363e-01, ...,\n",
       "            3.97165567e-01, -2.76256824e+00, -8.52143049e-01],\n",
       "          [ 6.69716075e-02, -9.54260170e-01,  1.19311929e-01, ...,\n",
       "           -1.53881264e+00, -1.74298191e+00,  3.59607965e-01],\n",
       "          [-7.32018113e-01,  4.93213266e-01, -5.64109206e-01, ...,\n",
       "           -7.41116464e-01, -9.25387621e-01, -1.10253537e+00],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "           -5.52441813e-02,  1.06430066e+00, -1.18865001e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            1.30857694e+00,  1.38141167e+00, -1.55681646e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            8.42483222e-01,  6.43368483e-01, -3.02491695e-01]],\n",
       "\n",
       "         [[-2.02444360e-01, -1.72587872e+00,  7.13476896e-01, ...,\n",
       "            3.48859280e-01, -2.53922582e+00, -7.26863444e-01],\n",
       "          [ 9.99126490e-03, -6.38578117e-01,  2.49122098e-01, ...,\n",
       "           -1.81174183e+00, -1.33073759e+00,  2.29745761e-01],\n",
       "          [-7.25089908e-01,  5.37292540e-01, -4.96881634e-01, ...,\n",
       "           -7.94185221e-01, -7.39986181e-01, -1.10269248e+00],\n",
       "...\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            1.26229286e+00,  1.26534927e+00, -1.82859862e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            9.84406292e-01,  9.35298443e-01, -6.32898271e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            2.53621340e-01,  1.39051303e-01, -5.49672604e-01]],\n",
       "\n",
       "         [[ 1.65044859e-01, -1.11025143e+00, -1.52399093e-02, ...,\n",
       "           -1.40346467e+00, -2.20732045e+00,  4.39427137e-01],\n",
       "          [-5.84007025e-01,  4.60170031e-01, -5.47049999e-01, ...,\n",
       "           -8.49560261e-01, -1.13359082e+00, -1.13874578e+00],\n",
       "          [-4.93100174e-02, -8.95264566e-01, -1.45338535e+00, ...,\n",
       "           -4.36942577e-01, -8.01668704e-01, -7.40049660e-01],\n",
       "          ...,\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            1.34661531e+00,  1.31328869e+00, -1.72961557e+00],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            9.30107117e-01,  7.11959362e-01, -5.06559551e-01],\n",
       "          [            nan,             nan,             nan, ...,\n",
       "            2.19540551e-01,  1.41294301e-01, -5.69608152e-01]]]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>time</span></div><div class='xr-var-dims'>(lat, lon, month, year, mode)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>1.0 1.0 1.0 ... 1.812e+03 1.812e+03</div><input id='attrs-696d5f06-99c3-43e3-bb5f-a5afa8870a61' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-696d5f06-99c3-43e3-bb5f-a5afa8870a61' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-40c1a8cb-3784-4cda-8a00-c7f65ab5867f' class='xr-var-data-in' type='checkbox'><label for='data-40c1a8cb-3784-4cda-8a00-c7f65ab5867f' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[[1.000e+00, 1.000e+00, 1.000e+00, ..., 1.000e+00, 1.000e+00,\n",
       "           1.000e+00],\n",
       "          [1.300e+01, 1.300e+01, 1.300e+01, ..., 1.300e+01, 1.300e+01,\n",
       "           1.300e+01],\n",
       "          [2.500e+01, 2.500e+01, 2.500e+01, ..., 2.500e+01, 2.500e+01,\n",
       "           2.500e+01],\n",
       "          ...,\n",
       "          [      nan,       nan,       nan, ..., 1.777e+03, 1.777e+03,\n",
       "           1.777e+03],\n",
       "          [      nan,       nan,       nan, ..., 1.789e+03, 1.789e+03,\n",
       "           1.789e+03],\n",
       "          [      nan,       nan,       nan, ..., 1.801e+03, 1.801e+03,\n",
       "           1.801e+03]],\n",
       "\n",
       "         [[2.000e+00, 2.000e+00, 2.000e+00, ..., 2.000e+00, 2.000e+00,\n",
       "           2.000e+00],\n",
       "          [1.400e+01, 1.400e+01, 1.400e+01, ..., 1.400e+01, 1.400e+01,\n",
       "           1.400e+01],\n",
       "          [2.600e+01, 2.600e+01, 2.600e+01, ..., 2.600e+01, 2.600e+01,\n",
       "           2.600e+01],\n",
       "...\n",
       "          [      nan,       nan,       nan, ..., 1.787e+03, 1.787e+03,\n",
       "           1.787e+03],\n",
       "          [      nan,       nan,       nan, ..., 1.799e+03, 1.799e+03,\n",
       "           1.799e+03],\n",
       "          [      nan,       nan,       nan, ..., 1.811e+03, 1.811e+03,\n",
       "           1.811e+03]],\n",
       "\n",
       "         [[1.200e+01, 1.200e+01, 1.200e+01, ..., 1.200e+01, 1.200e+01,\n",
       "           1.200e+01],\n",
       "          [2.400e+01, 2.400e+01, 2.400e+01, ..., 2.400e+01, 2.400e+01,\n",
       "           2.400e+01],\n",
       "          [3.600e+01, 3.600e+01, 3.600e+01, ..., 3.600e+01, 3.600e+01,\n",
       "           3.600e+01],\n",
       "          ...,\n",
       "          [      nan,       nan,       nan, ..., 1.788e+03, 1.788e+03,\n",
       "           1.788e+03],\n",
       "          [      nan,       nan,       nan, ..., 1.800e+03, 1.800e+03,\n",
       "           1.800e+03],\n",
       "          [      nan,       nan,       nan, ..., 1.812e+03, 1.812e+03,\n",
       "           1.812e+03]]]]])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-b7265089-ce4e-4224-aafc-15f0e7d51e25' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-b7265089-ce4e-4224-aafc-15f0e7d51e25' class='xr-section-summary'  title='Expand/collapse section'>Attributes: <span>(0)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><dl class='xr-attrs'></dl></div></li></ul></div></div>"
      ],
      "text/plain": [
       "<xarray.Dataset>\n",
       "Dimensions:  (lat: 24, lon: 72, mode: 33, month: 12, year: 151)\n",
       "Coordinates:\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "  * month    (month) int64 1 2 3 4 5 6 7 8 9 10 11 12\n",
       "  * year     (year) int64 1 2 3 4 5 6 7 8 9 ... 144 145 146 147 148 149 150 151\n",
       "  * mode     (mode) int64 10000 50001 50002 50003 ... 60012 60013 60014 60015\n",
       "Data variables:\n",
       "    index    (lat, lon, month, year, mode) float64 nan 2.265e+03 ... 9.632e+07\n",
       "    sst      (lat, lon, month, year, mode) float64 1.862 -0.3493 ... 0.252\n",
       "    t300     (lat, lon, month, year, mode) float64 0.3743 -0.7049 ... 0.2332\n",
       "    ua       (lat, lon, month, year, mode) float64 0.4293 -2.984 ... -1.701\n",
       "    va       (lat, lon, month, year, mode) float64 0.08719 0.07952 ... 2.318\n",
       "    nino     (lat, lon, month, year, mode) float64 -0.4072 -1.91 ... -0.5696\n",
       "    time     (lat, lon, month, year, mode) float64 1.0 1.0 ... 1.812e+03"
      ]
     },
     "execution_count": 577,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data_set"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 581,
   "metadata": {},
   "outputs": [],
   "source": [
    "data_set.to_netcdf(\"notebook/data_set.nc\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "data.to_csv(\"notebook/data_frame.csv\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## XR\n",
    "def trans(x):\n",
    "    temp=10000*(6-(x>2265))+(x<2266)*((x-1)//151+1)+(x>2265)*(((x-1)-2265)//140+1)#这里返回str报错\n",
    "    #<2266:CMIP6 >2265:CMIP5\n",
    "    #编码顺序开始5，6，1表示CMIP5,6,SODA 后面表示模式 从1计数 \n",
    "    return temp\n",
    "CMIP=CMIP.assign_coords(mode=(\"mode\",trans(CMIP.year)))\n",
    "CMIP"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 506,
   "metadata": {},
   "outputs": [
    {
     "ename": "ValueError",
     "evalue": "Dimension mode already exists.",
     "output_type": "error",
     "traceback": [
      "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[0;31mValueError\u001b[0m                                Traceback (most recent call last)",
      "\u001b[0;32m<ipython-input-506-6785c3faa57f>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mCMIP\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mexpand_dims\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m\"mode\"\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/dataset.py\u001b[0m in \u001b[0;36mexpand_dims\u001b[0;34m(self, dim, axis, **dim_kwargs)\u001b[0m\n\u001b[1;32m   3116\u001b[0m         \u001b[0;32mfor\u001b[0m \u001b[0md\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mdim\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   3117\u001b[0m             \u001b[0;32mif\u001b[0m \u001b[0md\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mdims\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 3118\u001b[0;31m                 \u001b[0;32mraise\u001b[0m \u001b[0mValueError\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34mf\"Dimension {d} already exists.\"\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m   3119\u001b[0m             \u001b[0;32mif\u001b[0m \u001b[0md\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_variables\u001b[0m \u001b[0;32mand\u001b[0m \u001b[0;32mnot\u001b[0m \u001b[0mutils\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mis_scalar\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_variables\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0md\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   3120\u001b[0m                 raise ValueError(\n",
      "\u001b[0;31mValueError\u001b[0m: Dimension mode already exists."
     ]
    }
   ],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 490,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div><svg style=\"position: absolute; width: 0; height: 0; overflow: hidden\">\n",
       "<defs>\n",
       "<symbol id=\"icon-database\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M16 0c-8.837 0-16 2.239-16 5v4c0 2.761 7.163 5 16 5s16-2.239 16-5v-4c0-2.761-7.163-5-16-5z\"></path>\n",
       "<path d=\"M16 17c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "<path d=\"M16 26c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "</symbol>\n",
       "<symbol id=\"icon-file-text2\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M28.681 7.159c-0.694-0.947-1.662-2.053-2.724-3.116s-2.169-2.030-3.116-2.724c-1.612-1.182-2.393-1.319-2.841-1.319h-15.5c-1.378 0-2.5 1.121-2.5 2.5v27c0 1.378 1.122 2.5 2.5 2.5h23c1.378 0 2.5-1.122 2.5-2.5v-19.5c0-0.448-0.137-1.23-1.319-2.841zM24.543 5.457c0.959 0.959 1.712 1.825 2.268 2.543h-4.811v-4.811c0.718 0.556 1.584 1.309 2.543 2.268zM28 29.5c0 0.271-0.229 0.5-0.5 0.5h-23c-0.271 0-0.5-0.229-0.5-0.5v-27c0-0.271 0.229-0.5 0.5-0.5 0 0 15.499-0 15.5 0v7c0 0.552 0.448 1 1 1h7v19.5z\"></path>\n",
       "<path d=\"M23 26h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 22h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 18h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "</symbol>\n",
       "</defs>\n",
       "</svg>\n",
       "<style>/* CSS stylesheet for displaying xarray objects in jupyterlab.\n",
       " *\n",
       " */\n",
       "\n",
       ":root {\n",
       "  --xr-font-color0: var(--jp-content-font-color0, rgba(0, 0, 0, 1));\n",
       "  --xr-font-color2: var(--jp-content-font-color2, rgba(0, 0, 0, 0.54));\n",
       "  --xr-font-color3: var(--jp-content-font-color3, rgba(0, 0, 0, 0.38));\n",
       "  --xr-border-color: var(--jp-border-color2, #e0e0e0);\n",
       "  --xr-disabled-color: var(--jp-layout-color3, #bdbdbd);\n",
       "  --xr-background-color: var(--jp-layout-color0, white);\n",
       "  --xr-background-color-row-even: var(--jp-layout-color1, white);\n",
       "  --xr-background-color-row-odd: var(--jp-layout-color2, #eeeeee);\n",
       "}\n",
       "\n",
       "html[theme=dark],\n",
       "body.vscode-dark {\n",
       "  --xr-font-color0: rgba(255, 255, 255, 1);\n",
       "  --xr-font-color2: rgba(255, 255, 255, 0.54);\n",
       "  --xr-font-color3: rgba(255, 255, 255, 0.38);\n",
       "  --xr-border-color: #1F1F1F;\n",
       "  --xr-disabled-color: #515151;\n",
       "  --xr-background-color: #111111;\n",
       "  --xr-background-color-row-even: #111111;\n",
       "  --xr-background-color-row-odd: #313131;\n",
       "}\n",
       "\n",
       ".xr-wrap {\n",
       "  display: block;\n",
       "  min-width: 300px;\n",
       "  max-width: 700px;\n",
       "}\n",
       "\n",
       ".xr-text-repr-fallback {\n",
       "  /* fallback to plain text repr when CSS is not injected (untrusted notebook) */\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-header {\n",
       "  padding-top: 6px;\n",
       "  padding-bottom: 6px;\n",
       "  margin-bottom: 4px;\n",
       "  border-bottom: solid 1px var(--xr-border-color);\n",
       "}\n",
       "\n",
       ".xr-header > div,\n",
       ".xr-header > ul {\n",
       "  display: inline;\n",
       "  margin-top: 0;\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-obj-type,\n",
       ".xr-array-name {\n",
       "  margin-left: 2px;\n",
       "  margin-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-obj-type {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-sections {\n",
       "  padding-left: 0 !important;\n",
       "  display: grid;\n",
       "  grid-template-columns: 150px auto auto 1fr 20px 20px;\n",
       "}\n",
       "\n",
       ".xr-section-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-section-item input {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-item input + label {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label {\n",
       "  cursor: pointer;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label:hover {\n",
       "  color: var(--xr-font-color0);\n",
       "}\n",
       "\n",
       ".xr-section-summary {\n",
       "  grid-column: 1;\n",
       "  color: var(--xr-font-color2);\n",
       "  font-weight: 500;\n",
       "}\n",
       "\n",
       ".xr-section-summary > span {\n",
       "  display: inline-block;\n",
       "  padding-left: 0.5em;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in + label:before {\n",
       "  display: inline-block;\n",
       "  content: '►';\n",
       "  font-size: 11px;\n",
       "  width: 15px;\n",
       "  text-align: center;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label:before {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label:before {\n",
       "  content: '▼';\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label > span {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-summary,\n",
       ".xr-section-inline-details {\n",
       "  padding-top: 4px;\n",
       "  padding-bottom: 4px;\n",
       "}\n",
       "\n",
       ".xr-section-inline-details {\n",
       "  grid-column: 2 / -1;\n",
       "}\n",
       "\n",
       ".xr-section-details {\n",
       "  display: none;\n",
       "  grid-column: 1 / -1;\n",
       "  margin-bottom: 5px;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked ~ .xr-section-details {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-array-wrap {\n",
       "  grid-column: 1 / -1;\n",
       "  display: grid;\n",
       "  grid-template-columns: 20px auto;\n",
       "}\n",
       "\n",
       ".xr-array-wrap > label {\n",
       "  grid-column: 1;\n",
       "  vertical-align: top;\n",
       "}\n",
       "\n",
       ".xr-preview {\n",
       "  color: var(--xr-font-color3);\n",
       "}\n",
       "\n",
       ".xr-array-preview,\n",
       ".xr-array-data {\n",
       "  padding: 0 5px !important;\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-array-data,\n",
       ".xr-array-in:checked ~ .xr-array-preview {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-array-in:checked ~ .xr-array-data,\n",
       ".xr-array-preview {\n",
       "  display: inline-block;\n",
       "}\n",
       "\n",
       ".xr-dim-list {\n",
       "  display: inline-block !important;\n",
       "  list-style: none;\n",
       "  padding: 0 !important;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list li {\n",
       "  display: inline-block;\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list:before {\n",
       "  content: '(';\n",
       "}\n",
       "\n",
       ".xr-dim-list:after {\n",
       "  content: ')';\n",
       "}\n",
       "\n",
       ".xr-dim-list li:not(:last-child):after {\n",
       "  content: ',';\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-has-index {\n",
       "  font-weight: bold;\n",
       "}\n",
       "\n",
       ".xr-var-list,\n",
       ".xr-var-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-var-item > div,\n",
       ".xr-var-item label,\n",
       ".xr-var-item > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-even);\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-var-item > .xr-var-name:hover span {\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-var-list > li:nth-child(odd) > div,\n",
       ".xr-var-list > li:nth-child(odd) > label,\n",
       ".xr-var-list > li:nth-child(odd) > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-odd);\n",
       "}\n",
       "\n",
       ".xr-var-name {\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-var-dims {\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-var-dtype {\n",
       "  grid-column: 3;\n",
       "  text-align: right;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-var-preview {\n",
       "  grid-column: 4;\n",
       "}\n",
       "\n",
       ".xr-var-name,\n",
       ".xr-var-dims,\n",
       ".xr-var-dtype,\n",
       ".xr-preview,\n",
       ".xr-attrs dt {\n",
       "  white-space: nowrap;\n",
       "  overflow: hidden;\n",
       "  text-overflow: ellipsis;\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-var-name:hover,\n",
       ".xr-var-dims:hover,\n",
       ".xr-var-dtype:hover,\n",
       ".xr-attrs dt:hover {\n",
       "  overflow: visible;\n",
       "  width: auto;\n",
       "  z-index: 1;\n",
       "}\n",
       "\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  display: none;\n",
       "  background-color: var(--xr-background-color) !important;\n",
       "  padding-bottom: 5px !important;\n",
       "}\n",
       "\n",
       ".xr-var-attrs-in:checked ~ .xr-var-attrs,\n",
       ".xr-var-data-in:checked ~ .xr-var-data {\n",
       "  display: block;\n",
       "}\n",
       "\n",
       ".xr-var-data > table {\n",
       "  float: right;\n",
       "}\n",
       "\n",
       ".xr-var-name span,\n",
       ".xr-var-data,\n",
       ".xr-attrs {\n",
       "  padding-left: 25px !important;\n",
       "}\n",
       "\n",
       ".xr-attrs,\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  grid-column: 1 / -1;\n",
       "}\n",
       "\n",
       "dl.xr-attrs {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  display: grid;\n",
       "  grid-template-columns: 125px auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt, dd {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  float: left;\n",
       "  padding-right: 10px;\n",
       "  width: auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt {\n",
       "  font-weight: normal;\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-attrs dt:hover span {\n",
       "  display: inline-block;\n",
       "  background: var(--xr-background-color);\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-attrs dd {\n",
       "  grid-column: 2;\n",
       "  white-space: pre-wrap;\n",
       "  word-break: break-all;\n",
       "}\n",
       "\n",
       ".xr-icon-database,\n",
       ".xr-icon-file-text2 {\n",
       "  display: inline-block;\n",
       "  vertical-align: middle;\n",
       "  width: 1em;\n",
       "  height: 1.5em !important;\n",
       "  stroke-width: 0;\n",
       "  stroke: currentColor;\n",
       "  fill: currentColor;\n",
       "}\n",
       "</style><pre class='xr-text-repr-fallback'>&lt;xarray.Dataset&gt;\n",
       "Dimensions:  (lat: 24, lon: 72, mode: 4645, time1: 55740)\n",
       "Coordinates:\n",
       "  * lat      (lat) float32 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float32 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "  * mode     (mode) int64 60001 60001 60001 60001 ... 50017 50017 50017 50017\n",
       "    time     (time1) int32 1 2 3 4 5 6 7 ... 1674 1675 1676 1677 1678 1679 1680\n",
       "  * time1    (time1) MultiIndex\n",
       "  - year     (time1) int64 1 1 1 1 1 1 1 1 1 ... 140 140 140 140 140 140 140 140\n",
       "  - month    (time1) int64 1 2 3 4 5 6 7 8 9 10 11 ... 2 3 4 5 6 7 8 9 10 11 12\n",
       "Data variables:\n",
       "    sst      (lat, lon, time1) float64 0.3464 0.222 0.3988 ... 0.5441 0.6906\n",
       "    t300     (lat, lon, time1) float64 -0.2449 -0.2425 -0.1634 ... 0.5012 0.5558\n",
       "    ua       (lat, lon, time1) float64 -1.68 2.064 0.2488 ... 1.135 3.162 4.196\n",
       "    va       (lat, lon, time1) float64 -0.4895 -2.865 -3.345 ... 2.361 -0.5992\n",
       "    nino     (time1) float64 -0.261 -0.1333 -0.01483 ... -0.4575 -0.4982 -0.4392</pre><div class='xr-wrap' hidden><div class='xr-header'><div class='xr-obj-type'>xarray.Dataset</div></div><ul class='xr-sections'><li class='xr-section-item'><input id='section-c221685b-d06b-45c0-903f-bb5cc55b150e' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-c221685b-d06b-45c0-903f-bb5cc55b150e' class='xr-section-summary'  title='Expand/collapse section'>Dimensions:</label><div class='xr-section-inline-details'><ul class='xr-dim-list'><li><span class='xr-has-index'>lat</span>: 24</li><li><span class='xr-has-index'>lon</span>: 72</li><li><span class='xr-has-index'>mode</span>: 4645</li><li><span class='xr-has-index'>time1</span>: 55740</li></ul></div><div class='xr-section-details'></div></li><li class='xr-section-item'><input id='section-0c76ac9a-0ee8-4842-ab3f-09899ef6f8d7' class='xr-section-summary-in' type='checkbox'  checked><label for='section-0c76ac9a-0ee8-4842-ab3f-09899ef6f8d7' class='xr-section-summary' >Coordinates: <span>(5)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lat</span></div><div class='xr-var-dims'>(lat)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>-55.0 -50.0 -45.0 ... 55.0 60.0</div><input id='attrs-6255ee25-9616-4815-9172-b32f8a3d31cc' class='xr-var-attrs-in' type='checkbox' ><label for='attrs-6255ee25-9616-4815-9172-b32f8a3d31cc' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-28615024-d9e6-42da-8d91-2fd2f9a451b9' class='xr-var-data-in' type='checkbox'><label for='data-28615024-d9e6-42da-8d91-2fd2f9a451b9' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'><dt><span>axis :</span></dt><dd>Y</dd><dt><span>units :</span></dt><dd>degrees_north</dd><dt><span>long_name :</span></dt><dd>latitude</dd><dt><span>standard_name :</span></dt><dd>latitude</dd></dl></div><div class='xr-var-data'><pre>array([-55., -50., -45., -40., -35., -30., -25., -20., -15., -10.,  -5.,   0.,\n",
       "         5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,  60.],\n",
       "      dtype=float32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lon</span></div><div class='xr-var-dims'>(lon)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>0.0 5.0 10.0 ... 345.0 350.0 355.0</div><input id='attrs-af56d5fa-f1f3-473b-be47-9831168a4c3b' class='xr-var-attrs-in' type='checkbox' ><label for='attrs-af56d5fa-f1f3-473b-be47-9831168a4c3b' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-d9dbd575-8c7c-4df0-9004-03e243bfe779' class='xr-var-data-in' type='checkbox'><label for='data-d9dbd575-8c7c-4df0-9004-03e243bfe779' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'><dt><span>axis :</span></dt><dd>X</dd><dt><span>units :</span></dt><dd>degrees_east</dd><dt><span>long_name :</span></dt><dd>longitude</dd><dt><span>standard_name :</span></dt><dd>longitude</dd></dl></div><div class='xr-var-data'><pre>array([  0.,   5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,\n",
       "        60.,  65.,  70.,  75.,  80.,  85.,  90.,  95., 100., 105., 110., 115.,\n",
       "       120., 125., 130., 135., 140., 145., 150., 155., 160., 165., 170., 175.,\n",
       "       180., 185., 190., 195., 200., 205., 210., 215., 220., 225., 230., 235.,\n",
       "       240., 245., 250., 255., 260., 265., 270., 275., 280., 285., 290., 295.,\n",
       "       300., 305., 310., 315., 320., 325., 330., 335., 340., 345., 350., 355.],\n",
       "      dtype=float32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>mode</span></div><div class='xr-var-dims'>(mode)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>60001 60001 60001 ... 50017 50017</div><input id='attrs-a59b4de9-5e77-4bf0-a7dd-35fee3ae1984' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-a59b4de9-5e77-4bf0-a7dd-35fee3ae1984' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-ca2b75e9-fd9e-4c4e-aa29-b305e7f95054' class='xr-var-data-in' type='checkbox'><label for='data-ca2b75e9-fd9e-4c4e-aa29-b305e7f95054' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([60001, 60001, 60001, ..., 50017, 50017, 50017])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>time</span></div><div class='xr-var-dims'>(time1)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 ... 1677 1678 1679 1680</div><input id='attrs-23aa4a67-2c65-4d49-806e-03b3728a350c' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-23aa4a67-2c65-4d49-806e-03b3728a350c' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-32f9eedc-afaf-45ff-bf34-d49e45dd6d84' class='xr-var-data-in' type='checkbox'><label for='data-32f9eedc-afaf-45ff-bf34-d49e45dd6d84' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([   1,    2,    3, ..., 1678, 1679, 1680], dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>time1</span></div><div class='xr-var-dims'>(time1)</div><div class='xr-var-dtype'>MultiIndex</div><div class='xr-var-preview xr-preview'>(year, month)</div><input id='attrs-9535c6e4-d705-43c9-bcab-37c31eb0d76c' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-9535c6e4-d705-43c9-bcab-37c31eb0d76c' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-f26dcdff-f749-44e0-8131-30561bc89b63' class='xr-var-data-in' type='checkbox'><label for='data-f26dcdff-f749-44e0-8131-30561bc89b63' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([(1, 1), (1, 2), (1, 3), ..., (140, 10), (140, 11), (140, 12)],\n",
       "      dtype=object)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>year</span></div><div class='xr-var-dims'>(time1)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>1 1 1 1 1 1 ... 140 140 140 140 140</div><input id='attrs-9b2e429e-d32f-4aa8-a7e8-1fca9b973174' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-9b2e429e-d32f-4aa8-a7e8-1fca9b973174' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-b54ecdc4-3c5d-4850-98b6-6bd4875d29e8' class='xr-var-data-in' type='checkbox'><label for='data-b54ecdc4-3c5d-4850-98b6-6bd4875d29e8' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  1,   1,   1, ..., 140, 140, 140])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>month</span></div><div class='xr-var-dims'>(time1)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 7 ... 6 7 8 9 10 11 12</div><input id='attrs-deafe0a4-1345-4867-95d1-26c40aef1190' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-deafe0a4-1345-4867-95d1-26c40aef1190' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-be07d45a-a00d-4833-9b5d-5c4185baadd1' class='xr-var-data-in' type='checkbox'><label for='data-be07d45a-a00d-4833-9b5d-5c4185baadd1' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([ 1,  2,  3, ..., 10, 11, 12])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-01f47e81-0ef2-4332-a7e3-2390494db7d3' class='xr-section-summary-in' type='checkbox'  checked><label for='section-01f47e81-0ef2-4332-a7e3-2390494db7d3' class='xr-section-summary' >Data variables: <span>(5)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span>sst</span></div><div class='xr-var-dims'>(lat, lon, time1)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.3464 0.222 ... 0.5441 0.6906</div><input id='attrs-187d1454-c184-49c4-a261-947b5b5cb80e' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-187d1454-c184-49c4-a261-947b5b5cb80e' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-c60f8054-24c8-4ea2-8c32-99e4d18cabee' class='xr-var-data-in' type='checkbox'><label for='data-c60f8054-24c8-4ea2-8c32-99e4d18cabee' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[ 3.46435547e-01,  2.22010851e-01,  3.98779154e-01, ...,\n",
       "          2.37213343e-01,  2.62474447e-01,  2.07749590e-01],\n",
       "        [ 3.04903030e-01,  9.32629108e-02,  1.87938452e-01, ...,\n",
       "          2.55185217e-01,  2.88914829e-01,  1.53324366e-01],\n",
       "        [ 2.32462883e-01,  5.45413494e-02,  3.17873955e-02, ...,\n",
       "          2.22427264e-01,  2.49719575e-01, -3.03041688e-05],\n",
       "        ...,\n",
       "        [-1.25169754e-03,  2.87953854e-01,  5.73102951e-01, ...,\n",
       "          8.66212189e-01,  9.15993869e-01,  8.28724027e-01],\n",
       "        [ 6.58988953e-04,  5.49411774e-03,  4.48052406e-01, ...,\n",
       "          7.73143411e-01,  8.56610477e-01,  7.19578266e-01],\n",
       "        [ 2.29776144e-01,  1.26200676e-01,  3.71894121e-01, ...,\n",
       "          3.19240749e-01,  3.87789428e-01,  3.66156310e-01]],\n",
       "\n",
       "       [[ 7.92360306e-03,  1.78332329e-02,  3.36525917e-01, ...,\n",
       "          6.38698101e-01,  6.83678448e-01,  6.17338836e-01],\n",
       "        [ 2.02001572e-01,  2.81116962e-01,  4.96657848e-01, ...,\n",
       "          5.36322296e-01,  6.21572852e-01,  5.44668794e-01],\n",
       "        [-3.77192497e-02,  5.64475060e-02,  6.90987587e-01, ...,\n",
       "          5.40471017e-01,  6.37215137e-01,  5.58478951e-01],\n",
       "...\n",
       "        [-4.82238770e-01, -5.11000633e-01, -4.48176384e-01, ...,\n",
       "          7.05539107e-01,  5.10893524e-01,  7.55427659e-01],\n",
       "        [-2.99921989e-01, -4.43178177e-01, -2.65554428e-01, ...,\n",
       "          6.49727583e-01,  5.23359597e-01,  7.62464821e-01],\n",
       "        [ 0.00000000e+00,  0.00000000e+00,  0.00000000e+00, ...,\n",
       "          8.18054616e-01,  4.55825061e-01,  1.00885415e+00]],\n",
       "\n",
       "       [[ 1.28334522e-01,  1.44913673e-01,  2.55995274e-01, ...,\n",
       "          6.12884521e-01,  7.26783812e-01,  8.11577439e-01],\n",
       "        [ 0.00000000e+00,  0.00000000e+00,  0.00000000e+00, ...,\n",
       "          6.45553052e-01,  8.28657687e-01,  9.31812227e-01],\n",
       "        [ 0.00000000e+00,  0.00000000e+00,  0.00000000e+00, ...,\n",
       "          8.91819894e-01,  1.16148043e+00,  1.34379268e+00],\n",
       "        ...,\n",
       "        [-1.96497917e-01, -2.17576027e-01, -2.08711147e-01, ...,\n",
       "          4.03339297e-01,  3.55969846e-01,  4.54161316e-01],\n",
       "        [-1.70331955e-01, -1.88989639e-01, -1.51929855e-01, ...,\n",
       "          4.68746811e-01,  4.50003028e-01,  5.17800272e-01],\n",
       "        [-1.12943649e-02, -1.52715683e-01, -3.87830734e-02, ...,\n",
       "          6.51521504e-01,  5.44134796e-01,  6.90551519e-01]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>t300</span></div><div class='xr-var-dims'>(lat, lon, time1)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-0.2449 -0.2425 ... 0.5012 0.5558</div><input id='attrs-852026f6-92ce-4d20-a5db-a9a4a155a575' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-852026f6-92ce-4d20-a5db-a9a4a155a575' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-07f998ae-bc36-4689-a8ac-12df214f4e09' class='xr-var-data-in' type='checkbox'><label for='data-07f998ae-bc36-4689-a8ac-12df214f4e09' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[-0.24488993, -0.24247554, -0.16343561, ...,  0.18224736,\n",
       "          0.20232385,  0.24252042],\n",
       "        [-0.29998431, -0.31077617, -0.25340953, ...,  0.22817011,\n",
       "          0.23514904,  0.25377479],\n",
       "        [-0.31292221, -0.36122006, -0.36631757, ...,  0.24742414,\n",
       "          0.24387066,  0.23095916],\n",
       "        ...,\n",
       "        [-0.15296087, -0.04722638,  0.00981518, ...,  0.49551582,\n",
       "          0.54140723,  0.54797173],\n",
       "        [-0.23834859, -0.20883487, -0.08487567, ...,  0.42451936,\n",
       "          0.47978947,  0.48905528],\n",
       "        [-0.2370799 , -0.21106389, -0.12609722, ...,  0.31152728,\n",
       "          0.34669036,  0.38451466]],\n",
       "\n",
       "       [[-0.38719967, -0.41139698, -0.33425263, ...,  0.61631465,\n",
       "          0.61778438,  0.60565656],\n",
       "        [-0.36165622, -0.32583469, -0.28292868, ...,  0.5460999 ,\n",
       "          0.56766045,  0.5575    ],\n",
       "        [-0.44733602, -0.39570141, -0.24875088, ...,  0.56612265,\n",
       "          0.58448267,  0.57557625],\n",
       "...\n",
       "        [-0.48213676, -0.51044995, -0.45143655, ...,  0.59784043,\n",
       "          0.54321927,  0.65934271],\n",
       "        [-0.29915935, -0.44243371, -0.27415848, ...,  0.55671108,\n",
       "          0.51916289,  0.61572713],\n",
       "        [ 0.        ,  0.        ,  0.        , ...,  0.70115739,\n",
       "          0.60764748,  0.8329342 ]],\n",
       "\n",
       "       [[ 0.12804584,  0.1452814 ,  0.26148167, ...,  0.6224032 ,\n",
       "          0.65538609,  0.75851119],\n",
       "        [ 0.        ,  0.        ,  0.        , ...,  0.56918848,\n",
       "          0.76028162,  0.81841165],\n",
       "        [ 0.        ,  0.        ,  0.        , ...,  0.7575022 ,\n",
       "          1.08533168,  1.10693276],\n",
       "        ...,\n",
       "        [-0.19356413, -0.22070296, -0.20555484, ...,  0.4338682 ,\n",
       "          0.38074392,  0.38956884],\n",
       "        [-0.16740631, -0.19020791, -0.1508411 , ...,  0.40882862,\n",
       "          0.41728029,  0.44226992],\n",
       "        [-0.01038933, -0.15191703, -0.03745374, ...,  0.48037806,\n",
       "          0.5012145 ,  0.55583608]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>ua</span></div><div class='xr-var-dims'>(lat, lon, time1)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-1.68 2.064 0.2488 ... 3.162 4.196</div><input id='attrs-dbaad09a-c093-4a74-a421-39fa65dc8d65' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-dbaad09a-c093-4a74-a421-39fa65dc8d65' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-9c42f02a-f30e-46f6-91ec-3dbf4d8e1004' class='xr-var-data-in' type='checkbox'><label for='data-9c42f02a-f30e-46f6-91ec-3dbf4d8e1004' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[-1.68026447e+00,  2.06386089e+00,  2.48803139e-01, ...,\n",
       "          1.22487926e+00,  2.60987473e+00,  3.42464542e+00],\n",
       "        [-1.94738150e+00,  2.75680637e+00,  1.37019157e-01, ...,\n",
       "          1.51785564e+00,  2.51727247e+00,  3.61949682e+00],\n",
       "        [-1.44550133e+00,  3.49950314e+00, -2.35633850e-01, ...,\n",
       "          1.65881252e+00,  2.27889347e+00,  3.58732224e+00],\n",
       "        ...,\n",
       "        [ 6.94131374e-01,  6.45240784e-01, -1.92093849e-01, ...,\n",
       "         -4.84678268e-01,  2.84826851e+00,  2.98491287e+00],\n",
       "        [ 3.38473320e-01,  9.45604324e-01, -1.27094269e-01, ...,\n",
       "          5.00220776e-01,  2.85620403e+00,  3.12072182e+00],\n",
       "        [-5.98807812e-01,  1.41000843e+00,  1.20628357e-01, ...,\n",
       "          1.06331444e+00,  2.72650290e+00,  3.23333454e+00]],\n",
       "\n",
       "       [[-2.62472153e-01,  6.94091797e-01, -1.75158501e-01, ...,\n",
       "          1.66417313e+00,  5.87739944e-02,  2.44688797e+00],\n",
       "        [-6.16315842e-01,  1.52786160e+00, -5.10197639e-01, ...,\n",
       "          1.78282166e+00,  2.77921677e-01,  2.35796165e+00],\n",
       "        [-9.73206520e-01,  1.89180183e+00, -8.55435371e-01, ...,\n",
       "          2.01383591e+00,  1.15585327e-01,  2.27769470e+00],\n",
       "...\n",
       "        [ 3.91845751e+00,  1.67225170e+00, -5.90636110e+00, ...,\n",
       "          1.26875877e+00,  1.24783278e+00,  1.33264637e+00],\n",
       "        [ 3.31677389e+00,  3.21177959e-01, -5.21944475e+00, ...,\n",
       "          3.85111809e-01,  9.98216152e-01,  1.61993790e+00],\n",
       "        [ 2.16631365e+00, -5.13300896e-01, -3.49244285e+00, ...,\n",
       "          5.96044064e-02,  3.90886784e-01,  1.36033034e+00]],\n",
       "\n",
       "       [[ 2.60495424e+00, -1.56714058e+00,  1.40633583e-01, ...,\n",
       "          1.54007244e+00,  2.83784080e+00,  3.43204308e+00],\n",
       "        [ 1.58557892e+00, -3.34566212e+00,  7.13619828e-01, ...,\n",
       "          1.83776069e+00,  1.88792992e+00,  3.77906799e+00],\n",
       "        [ 6.45871282e-01, -3.17181587e+00,  1.20542657e+00, ...,\n",
       "          1.50365984e+00,  6.44994676e-01,  3.46377134e+00],\n",
       "        ...,\n",
       "        [ 2.73322797e+00, -3.63768101e-01, -4.93430710e+00, ...,\n",
       "          1.89204621e+00,  3.87789917e+00,  5.41085243e+00],\n",
       "        [ 3.76429558e+00, -7.22814322e-01, -2.94454670e+00, ...,\n",
       "          9.63971376e-01,  3.66673517e+00,  5.01622200e+00],\n",
       "        [ 3.74643803e+00, -1.09673977e+00, -1.09898281e+00, ...,\n",
       "          1.13468647e+00,  3.16195202e+00,  4.19634628e+00]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>va</span></div><div class='xr-var-dims'>(lat, lon, time1)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-0.4895 -2.865 ... 2.361 -0.5992</div><input id='attrs-66a9f77c-b770-4ef5-bef6-88f53248a9aa' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-66a9f77c-b770-4ef5-bef6-88f53248a9aa' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-099fe141-1bfc-4ff1-87be-af85f07ba3c1' class='xr-var-data-in' type='checkbox'><label for='data-099fe141-1bfc-4ff1-87be-af85f07ba3c1' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[-4.89485741e-01, -2.86467457e+00, -3.34482908e+00, ...,\n",
       "          9.40165520e-02, -1.99299836e+00,  4.11126614e-02],\n",
       "        [-8.99670959e-01, -2.26985478e+00, -3.05975056e+00, ...,\n",
       "         -1.50060654e-03, -1.28009367e+00,  5.86354733e-03],\n",
       "        [-1.22944093e+00, -1.49536514e+00, -2.19721699e+00, ...,\n",
       "         -1.70307875e-01, -9.73856211e-01, -1.22617364e-01],\n",
       "        ...,\n",
       "        [ 1.28711724e+00, -3.71335268e+00, -1.48849893e+00, ...,\n",
       "          5.90524197e-01, -4.20652485e+00,  2.32449293e-01],\n",
       "        [ 1.16360927e+00, -3.91472435e+00, -2.32185173e+00, ...,\n",
       "          3.51500034e-01, -3.52802515e+00,  2.73556709e-01],\n",
       "        [ 3.57711792e-01, -3.54387307e+00, -3.05497050e+00, ...,\n",
       "          1.19835854e-01, -2.84895086e+00,  1.48566246e-01]],\n",
       "\n",
       "       [[-9.93368626e-02, -3.82471418e+00, -2.24221992e+00, ...,\n",
       "         -3.11930895e-01, -4.35569048e-01,  9.30527449e-02],\n",
       "        [-8.53304148e-01, -2.70542407e+00, -1.03325772e+00, ...,\n",
       "         -1.92634583e-01, -1.83842421e-01,  2.33215809e-01],\n",
       "        [-1.21119046e+00, -1.53594756e+00,  3.15382481e-02, ...,\n",
       "         -1.30091429e-01,  3.50306034e-02,  2.52229512e-01],\n",
       "...\n",
       "        [ 1.27941489e+00, -2.43457198e+00,  2.10832453e+00, ...,\n",
       "          1.35751629e+00,  1.61307657e+00,  3.31242800e-01],\n",
       "        [ 8.04094315e-01, -9.96949196e-01,  1.03386331e+00, ...,\n",
       "          1.64782166e+00,  1.92796516e+00, -1.06621981e+00],\n",
       "        [ 9.37990665e-01,  5.71668386e-01,  3.43707323e-01, ...,\n",
       "          1.17898607e+00,  1.06725359e+00, -1.10557008e+00]],\n",
       "\n",
       "       [[ 5.12831926e-01,  1.11855173e+00, -6.55462980e-01, ...,\n",
       "          1.60397005e+00,  1.61532986e+00, -1.15677786e+00],\n",
       "        [ 1.27940369e+00,  2.58754778e+00,  9.00030136e-02, ...,\n",
       "          9.17344332e-01,  1.43914962e+00, -2.05824113e+00],\n",
       "        [ 9.68593478e-01,  1.72512317e+00,  7.94457197e-02, ...,\n",
       "          6.40919685e-01,  7.46282578e-01, -8.14694762e-01],\n",
       "        ...,\n",
       "        [-9.08248425e-02,  1.10319138e+00,  1.58480883e-01, ...,\n",
       "          2.01258969e+00,  2.95068502e+00,  9.65872645e-01],\n",
       "        [-1.28134012e-01, -2.76764393e-01, -5.22965193e-01, ...,\n",
       "          2.30579281e+00,  2.60838842e+00,  5.45163751e-02],\n",
       "        [-1.99754000e-01,  1.81902170e-01, -9.10647392e-01, ...,\n",
       "          2.10718369e+00,  2.36143923e+00, -5.99186182e-01]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>nino</span></div><div class='xr-var-dims'>(time1)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-0.261 -0.1333 ... -0.4982 -0.4392</div><input id='attrs-c67bd423-697c-4997-bbac-b6b408881a09' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-c67bd423-697c-4997-bbac-b6b408881a09' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-b67f81df-6c3f-407c-bf5f-855913245b30' class='xr-var-data-in' type='checkbox'><label for='data-b67f81df-6c3f-407c-bf5f-855913245b30' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([-0.26102549, -0.13325377, -0.01483156, ..., -0.45745715,\n",
       "       -0.4982231 , -0.43920282])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-a0cb1ce0-ca3a-474f-ae40-9451c8d7fc39' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-a0cb1ce0-ca3a-474f-ae40-9451c8d7fc39' class='xr-section-summary'  title='Expand/collapse section'>Attributes: <span>(0)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><dl class='xr-attrs'></dl></div></li></ul></div></div>"
      ],
      "text/plain": [
       "<xarray.Dataset>\n",
       "Dimensions:  (lat: 24, lon: 72, mode: 4645, time1: 55740)\n",
       "Coordinates:\n",
       "  * lat      (lat) float32 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float32 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "  * mode     (mode) int64 60001 60001 60001 60001 ... 50017 50017 50017 50017\n",
       "    time     (time1) int32 1 2 3 4 5 6 7 ... 1674 1675 1676 1677 1678 1679 1680\n",
       "  * time1    (time1) MultiIndex\n",
       "  - year     (time1) int64 1 1 1 1 1 1 1 1 1 ... 140 140 140 140 140 140 140 140\n",
       "  - month    (time1) int64 1 2 3 4 5 6 7 8 9 10 11 ... 2 3 4 5 6 7 8 9 10 11 12\n",
       "Data variables:\n",
       "    sst      (lat, lon, time1) float64 0.3464 0.222 0.3988 ... 0.5441 0.6906\n",
       "    t300     (lat, lon, time1) float64 -0.2449 -0.2425 -0.1634 ... 0.5012 0.5558\n",
       "    ua       (lat, lon, time1) float64 -1.68 2.064 0.2488 ... 1.135 3.162 4.196\n",
       "    va       (lat, lon, time1) float64 -0.4895 -2.865 -3.345 ... 2.361 -0.5992\n",
       "    nino     (time1) float64 -0.261 -0.1333 -0.01483 ... -0.4575 -0.4982 -0.4392"
      ]
     },
     "execution_count": 490,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "CMIP"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "def transyear(x):#因为遍历规则，不能对X比较大小 报错ambiguous\n",
    "    temp=(x<2266)*((x-1)%151+1)+(x>2265)*((x-1-2265)%140+1)#年份的顺序，计数从1开始\n",
    "    return temp\n",
    "CMIP['year']=CMIP.year.pipe(transyear)\n",
    "CMIP"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 479,
   "metadata": {},
   "outputs": [],
   "source": [
    "#CMIP=CMIP.stack(time=[\"year\", \"month\"])#datetime不适用，因为没有日期，且修改coords时参数为tuple时pipe报错"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "CMIP['time']=CMIP.year*12+CMIP.month-12"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#CMIP=CMIP.assign_coords(time=(\"time\",CMIP.year*12+CMIP.month-12))\n",
    "CMIP=CMIP.set_coords('time')\n",
    "CMIP"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": []
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#CMIP.load()\n",
    "#CMIP=CMIP.persist()\n",
    "#CMIP=CMIP.stack(time1=[\"year\",'month'])#去除标签重复值\n",
    "CMIP=CMIP.unstack(\"time1\")\n",
    "CMIP"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 432,
   "metadata": {},
   "outputs": [],
   "source": [
    "#CMIP.load()\n",
    "#CMIP=CMIP.persist()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 372,
   "metadata": {},
   "outputs": [],
   "source": [
    "#xr.concat([CMIP.sel(mode=i) for i in CMIP.mode.values], \"time\")报错了\n",
    "#CMIP.time=CMIP.time.pipe(lambda x:datetime(x+(1,0,0))) 报错了"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 374,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div><svg style=\"position: absolute; width: 0; height: 0; overflow: hidden\">\n",
       "<defs>\n",
       "<symbol id=\"icon-database\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M16 0c-8.837 0-16 2.239-16 5v4c0 2.761 7.163 5 16 5s16-2.239 16-5v-4c0-2.761-7.163-5-16-5z\"></path>\n",
       "<path d=\"M16 17c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "<path d=\"M16 26c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "</symbol>\n",
       "<symbol id=\"icon-file-text2\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M28.681 7.159c-0.694-0.947-1.662-2.053-2.724-3.116s-2.169-2.030-3.116-2.724c-1.612-1.182-2.393-1.319-2.841-1.319h-15.5c-1.378 0-2.5 1.121-2.5 2.5v27c0 1.378 1.122 2.5 2.5 2.5h23c1.378 0 2.5-1.122 2.5-2.5v-19.5c0-0.448-0.137-1.23-1.319-2.841zM24.543 5.457c0.959 0.959 1.712 1.825 2.268 2.543h-4.811v-4.811c0.718 0.556 1.584 1.309 2.543 2.268zM28 29.5c0 0.271-0.229 0.5-0.5 0.5h-23c-0.271 0-0.5-0.229-0.5-0.5v-27c0-0.271 0.229-0.5 0.5-0.5 0 0 15.499-0 15.5 0v7c0 0.552 0.448 1 1 1h7v19.5z\"></path>\n",
       "<path d=\"M23 26h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 22h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 18h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "</symbol>\n",
       "</defs>\n",
       "</svg>\n",
       "<style>/* CSS stylesheet for displaying xarray objects in jupyterlab.\n",
       " *\n",
       " */\n",
       "\n",
       ":root {\n",
       "  --xr-font-color0: var(--jp-content-font-color0, rgba(0, 0, 0, 1));\n",
       "  --xr-font-color2: var(--jp-content-font-color2, rgba(0, 0, 0, 0.54));\n",
       "  --xr-font-color3: var(--jp-content-font-color3, rgba(0, 0, 0, 0.38));\n",
       "  --xr-border-color: var(--jp-border-color2, #e0e0e0);\n",
       "  --xr-disabled-color: var(--jp-layout-color3, #bdbdbd);\n",
       "  --xr-background-color: var(--jp-layout-color0, white);\n",
       "  --xr-background-color-row-even: var(--jp-layout-color1, white);\n",
       "  --xr-background-color-row-odd: var(--jp-layout-color2, #eeeeee);\n",
       "}\n",
       "\n",
       "html[theme=dark],\n",
       "body.vscode-dark {\n",
       "  --xr-font-color0: rgba(255, 255, 255, 1);\n",
       "  --xr-font-color2: rgba(255, 255, 255, 0.54);\n",
       "  --xr-font-color3: rgba(255, 255, 255, 0.38);\n",
       "  --xr-border-color: #1F1F1F;\n",
       "  --xr-disabled-color: #515151;\n",
       "  --xr-background-color: #111111;\n",
       "  --xr-background-color-row-even: #111111;\n",
       "  --xr-background-color-row-odd: #313131;\n",
       "}\n",
       "\n",
       ".xr-wrap {\n",
       "  display: block;\n",
       "  min-width: 300px;\n",
       "  max-width: 700px;\n",
       "}\n",
       "\n",
       ".xr-text-repr-fallback {\n",
       "  /* fallback to plain text repr when CSS is not injected (untrusted notebook) */\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-header {\n",
       "  padding-top: 6px;\n",
       "  padding-bottom: 6px;\n",
       "  margin-bottom: 4px;\n",
       "  border-bottom: solid 1px var(--xr-border-color);\n",
       "}\n",
       "\n",
       ".xr-header > div,\n",
       ".xr-header > ul {\n",
       "  display: inline;\n",
       "  margin-top: 0;\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-obj-type,\n",
       ".xr-array-name {\n",
       "  margin-left: 2px;\n",
       "  margin-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-obj-type {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-sections {\n",
       "  padding-left: 0 !important;\n",
       "  display: grid;\n",
       "  grid-template-columns: 150px auto auto 1fr 20px 20px;\n",
       "}\n",
       "\n",
       ".xr-section-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-section-item input {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-item input + label {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label {\n",
       "  cursor: pointer;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label:hover {\n",
       "  color: var(--xr-font-color0);\n",
       "}\n",
       "\n",
       ".xr-section-summary {\n",
       "  grid-column: 1;\n",
       "  color: var(--xr-font-color2);\n",
       "  font-weight: 500;\n",
       "}\n",
       "\n",
       ".xr-section-summary > span {\n",
       "  display: inline-block;\n",
       "  padding-left: 0.5em;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in + label:before {\n",
       "  display: inline-block;\n",
       "  content: '►';\n",
       "  font-size: 11px;\n",
       "  width: 15px;\n",
       "  text-align: center;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label:before {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label:before {\n",
       "  content: '▼';\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label > span {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-summary,\n",
       ".xr-section-inline-details {\n",
       "  padding-top: 4px;\n",
       "  padding-bottom: 4px;\n",
       "}\n",
       "\n",
       ".xr-section-inline-details {\n",
       "  grid-column: 2 / -1;\n",
       "}\n",
       "\n",
       ".xr-section-details {\n",
       "  display: none;\n",
       "  grid-column: 1 / -1;\n",
       "  margin-bottom: 5px;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked ~ .xr-section-details {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-array-wrap {\n",
       "  grid-column: 1 / -1;\n",
       "  display: grid;\n",
       "  grid-template-columns: 20px auto;\n",
       "}\n",
       "\n",
       ".xr-array-wrap > label {\n",
       "  grid-column: 1;\n",
       "  vertical-align: top;\n",
       "}\n",
       "\n",
       ".xr-preview {\n",
       "  color: var(--xr-font-color3);\n",
       "}\n",
       "\n",
       ".xr-array-preview,\n",
       ".xr-array-data {\n",
       "  padding: 0 5px !important;\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-array-data,\n",
       ".xr-array-in:checked ~ .xr-array-preview {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-array-in:checked ~ .xr-array-data,\n",
       ".xr-array-preview {\n",
       "  display: inline-block;\n",
       "}\n",
       "\n",
       ".xr-dim-list {\n",
       "  display: inline-block !important;\n",
       "  list-style: none;\n",
       "  padding: 0 !important;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list li {\n",
       "  display: inline-block;\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list:before {\n",
       "  content: '(';\n",
       "}\n",
       "\n",
       ".xr-dim-list:after {\n",
       "  content: ')';\n",
       "}\n",
       "\n",
       ".xr-dim-list li:not(:last-child):after {\n",
       "  content: ',';\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-has-index {\n",
       "  font-weight: bold;\n",
       "}\n",
       "\n",
       ".xr-var-list,\n",
       ".xr-var-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-var-item > div,\n",
       ".xr-var-item label,\n",
       ".xr-var-item > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-even);\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-var-item > .xr-var-name:hover span {\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-var-list > li:nth-child(odd) > div,\n",
       ".xr-var-list > li:nth-child(odd) > label,\n",
       ".xr-var-list > li:nth-child(odd) > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-odd);\n",
       "}\n",
       "\n",
       ".xr-var-name {\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-var-dims {\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-var-dtype {\n",
       "  grid-column: 3;\n",
       "  text-align: right;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-var-preview {\n",
       "  grid-column: 4;\n",
       "}\n",
       "\n",
       ".xr-var-name,\n",
       ".xr-var-dims,\n",
       ".xr-var-dtype,\n",
       ".xr-preview,\n",
       ".xr-attrs dt {\n",
       "  white-space: nowrap;\n",
       "  overflow: hidden;\n",
       "  text-overflow: ellipsis;\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-var-name:hover,\n",
       ".xr-var-dims:hover,\n",
       ".xr-var-dtype:hover,\n",
       ".xr-attrs dt:hover {\n",
       "  overflow: visible;\n",
       "  width: auto;\n",
       "  z-index: 1;\n",
       "}\n",
       "\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  display: none;\n",
       "  background-color: var(--xr-background-color) !important;\n",
       "  padding-bottom: 5px !important;\n",
       "}\n",
       "\n",
       ".xr-var-attrs-in:checked ~ .xr-var-attrs,\n",
       ".xr-var-data-in:checked ~ .xr-var-data {\n",
       "  display: block;\n",
       "}\n",
       "\n",
       ".xr-var-data > table {\n",
       "  float: right;\n",
       "}\n",
       "\n",
       ".xr-var-name span,\n",
       ".xr-var-data,\n",
       ".xr-attrs {\n",
       "  padding-left: 25px !important;\n",
       "}\n",
       "\n",
       ".xr-attrs,\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  grid-column: 1 / -1;\n",
       "}\n",
       "\n",
       "dl.xr-attrs {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  display: grid;\n",
       "  grid-template-columns: 125px auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt, dd {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  float: left;\n",
       "  padding-right: 10px;\n",
       "  width: auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt {\n",
       "  font-weight: normal;\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-attrs dt:hover span {\n",
       "  display: inline-block;\n",
       "  background: var(--xr-background-color);\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-attrs dd {\n",
       "  grid-column: 2;\n",
       "  white-space: pre-wrap;\n",
       "  word-break: break-all;\n",
       "}\n",
       "\n",
       ".xr-icon-database,\n",
       ".xr-icon-file-text2 {\n",
       "  display: inline-block;\n",
       "  vertical-align: middle;\n",
       "  width: 1em;\n",
       "  height: 1.5em !important;\n",
       "  stroke-width: 0;\n",
       "  stroke: currentColor;\n",
       "  fill: currentColor;\n",
       "}\n",
       "</style><pre class='xr-text-repr-fallback'>&lt;xarray.Dataset&gt;\n",
       "Dimensions:  (lat: 24, lon: 72, month: 36, year: 100)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 ... 28 29 30 31 32 33 34 35 36\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "Data variables:\n",
       "    sst      (year, month, lat, lon) float32 ...\n",
       "    t300     (year, month, lat, lon) float32 ...\n",
       "    ua       (year, month, lat, lon) float64 ...\n",
       "    va       (year, month, lat, lon) float64 ...</pre><div class='xr-wrap' hidden><div class='xr-header'><div class='xr-obj-type'>xarray.Dataset</div></div><ul class='xr-sections'><li class='xr-section-item'><input id='section-0e9d6bb7-1377-40fc-b6e2-4832ef7f3c89' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-0e9d6bb7-1377-40fc-b6e2-4832ef7f3c89' class='xr-section-summary'  title='Expand/collapse section'>Dimensions:</label><div class='xr-section-inline-details'><ul class='xr-dim-list'><li><span class='xr-has-index'>lat</span>: 24</li><li><span class='xr-has-index'>lon</span>: 72</li><li><span class='xr-has-index'>month</span>: 36</li><li><span class='xr-has-index'>year</span>: 100</li></ul></div><div class='xr-section-details'></div></li><li class='xr-section-item'><input id='section-0a6e39ad-ab98-4d79-9cce-7ea024af864b' class='xr-section-summary-in' type='checkbox'  checked><label for='section-0a6e39ad-ab98-4d79-9cce-7ea024af864b' class='xr-section-summary' >Coordinates: <span>(4)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>year</span></div><div class='xr-var-dims'>(year)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 ... 95 96 97 98 99 100</div><input id='attrs-2a49ff8f-8ee8-46c7-928d-c86426c39f8f' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-2a49ff8f-8ee8-46c7-928d-c86426c39f8f' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-b3fb25d1-59dc-4f41-9cfb-e56325138934' class='xr-var-data-in' type='checkbox'><label for='data-b3fb25d1-59dc-4f41-9cfb-e56325138934' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  1,   2,   3,   4,   5,   6,   7,   8,   9,  10,  11,  12,  13,  14,\n",
       "        15,  16,  17,  18,  19,  20,  21,  22,  23,  24,  25,  26,  27,  28,\n",
       "        29,  30,  31,  32,  33,  34,  35,  36,  37,  38,  39,  40,  41,  42,\n",
       "        43,  44,  45,  46,  47,  48,  49,  50,  51,  52,  53,  54,  55,  56,\n",
       "        57,  58,  59,  60,  61,  62,  63,  64,  65,  66,  67,  68,  69,  70,\n",
       "        71,  72,  73,  74,  75,  76,  77,  78,  79,  80,  81,  82,  83,  84,\n",
       "        85,  86,  87,  88,  89,  90,  91,  92,  93,  94,  95,  96,  97,  98,\n",
       "        99, 100], dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>month</span></div><div class='xr-var-dims'>(month)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 7 ... 31 32 33 34 35 36</div><input id='attrs-519fa80a-4ca3-470b-8a1f-da7e3ca9ecd2' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-519fa80a-4ca3-470b-8a1f-da7e3ca9ecd2' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-7ebbdc98-f9c0-4be3-bd53-a0d3b0fe851a' class='xr-var-data-in' type='checkbox'><label for='data-7ebbdc98-f9c0-4be3-bd53-a0d3b0fe851a' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12, 13, 14, 15, 16, 17, 18,\n",
       "       19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36],\n",
       "      dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lat</span></div><div class='xr-var-dims'>(lat)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-55.0 -50.0 -45.0 ... 55.0 60.0</div><input id='attrs-fa41063e-6242-4224-9d80-bc55f5e8813a' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-fa41063e-6242-4224-9d80-bc55f5e8813a' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-3a4edcf9-0c2d-4111-a162-24728c33ab74' class='xr-var-data-in' type='checkbox'><label for='data-3a4edcf9-0c2d-4111-a162-24728c33ab74' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([-55., -50., -45., -40., -35., -30., -25., -20., -15., -10.,  -5.,   0.,\n",
       "         5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,  60.])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lon</span></div><div class='xr-var-dims'>(lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.0 5.0 10.0 ... 345.0 350.0 355.0</div><input id='attrs-4ea99543-aec7-4ed8-8fc0-f3388d77739d' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-4ea99543-aec7-4ed8-8fc0-f3388d77739d' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-e5bc9696-50b4-4ae3-8e47-084a71b7ce04' class='xr-var-data-in' type='checkbox'><label for='data-e5bc9696-50b4-4ae3-8e47-084a71b7ce04' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  0.,   5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,\n",
       "        60.,  65.,  70.,  75.,  80.,  85.,  90.,  95., 100., 105., 110., 115.,\n",
       "       120., 125., 130., 135., 140., 145., 150., 155., 160., 165., 170., 175.,\n",
       "       180., 185., 190., 195., 200., 205., 210., 215., 220., 225., 230., 235.,\n",
       "       240., 245., 250., 255., 260., 265., 270., 275., 280., 285., 290., 295.,\n",
       "       300., 305., 310., 315., 320., 325., 330., 335., 340., 345., 350., 355.])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-23bb08ab-07f5-48a2-b850-4e756f8a219a' class='xr-section-summary-in' type='checkbox'  checked><label for='section-23bb08ab-07f5-48a2-b850-4e756f8a219a' class='xr-section-summary' >Data variables: <span>(4)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span>sst</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-9e379a1e-0def-425f-a21b-14cb7439c0e6' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-9e379a1e-0def-425f-a21b-14cb7439c0e6' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-6f9ec7b2-a040-48a1-ac18-80d4ea2a65d0' class='xr-var-data-in' type='checkbox'><label for='data-6f9ec7b2-a040-48a1-ac18-80d4ea2a65d0' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[6220800 values with dtype=float32]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>t300</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-c75ae927-9624-4208-bac6-60c98c9b7adf' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-c75ae927-9624-4208-bac6-60c98c9b7adf' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-fd2ef96e-6d8b-49a8-8a16-c222f6ce3db1' class='xr-var-data-in' type='checkbox'><label for='data-fd2ef96e-6d8b-49a8-8a16-c222f6ce3db1' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[6220800 values with dtype=float32]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>ua</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-39f78199-62c8-484e-a14f-db14760ed806' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-39f78199-62c8-484e-a14f-db14760ed806' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-10c20aa5-25f3-4e34-a74d-66cf89c1d68b' class='xr-var-data-in' type='checkbox'><label for='data-10c20aa5-25f3-4e34-a74d-66cf89c1d68b' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[6220800 values with dtype=float64]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>va</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-3ee07919-f2ea-4d57-9e48-057bdebd945e' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-3ee07919-f2ea-4d57-9e48-057bdebd945e' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-b720ce30-6895-4fc4-a852-748d190d7870' class='xr-var-data-in' type='checkbox'><label for='data-b720ce30-6895-4fc4-a852-748d190d7870' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[6220800 values with dtype=float64]</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-ba50ffc4-1acf-4e0d-b5c2-3d558b0051db' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-ba50ffc4-1acf-4e0d-b5c2-3d558b0051db' class='xr-section-summary'  title='Expand/collapse section'>Attributes: <span>(0)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><dl class='xr-attrs'></dl></div></li></ul></div></div>"
      ],
      "text/plain": [
       "<xarray.Dataset>\n",
       "Dimensions:  (lat: 24, lon: 72, month: 36, year: 100)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 ... 28 29 30 31 32 33 34 35 36\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "Data variables:\n",
       "    sst      (year, month, lat, lon) float32 ...\n",
       "    t300     (year, month, lat, lon) float32 ...\n",
       "    ua       (year, month, lat, lon) float64 ...\n",
       "    va       (year, month, lat, lon) float64 ..."
      ]
     },
     "execution_count": 374,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "c=nc.Dataset('../tcdata/enso_round1_train_20210201/SODA_train.nc')\n",
    "C= xr.open_dataset(xr.backends.NetCDF4DataStore(c))\n",
    "C"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 375,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div><svg style=\"position: absolute; width: 0; height: 0; overflow: hidden\">\n",
       "<defs>\n",
       "<symbol id=\"icon-database\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M16 0c-8.837 0-16 2.239-16 5v4c0 2.761 7.163 5 16 5s16-2.239 16-5v-4c0-2.761-7.163-5-16-5z\"></path>\n",
       "<path d=\"M16 17c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "<path d=\"M16 26c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "</symbol>\n",
       "<symbol id=\"icon-file-text2\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M28.681 7.159c-0.694-0.947-1.662-2.053-2.724-3.116s-2.169-2.030-3.116-2.724c-1.612-1.182-2.393-1.319-2.841-1.319h-15.5c-1.378 0-2.5 1.121-2.5 2.5v27c0 1.378 1.122 2.5 2.5 2.5h23c1.378 0 2.5-1.122 2.5-2.5v-19.5c0-0.448-0.137-1.23-1.319-2.841zM24.543 5.457c0.959 0.959 1.712 1.825 2.268 2.543h-4.811v-4.811c0.718 0.556 1.584 1.309 2.543 2.268zM28 29.5c0 0.271-0.229 0.5-0.5 0.5h-23c-0.271 0-0.5-0.229-0.5-0.5v-27c0-0.271 0.229-0.5 0.5-0.5 0 0 15.499-0 15.5 0v7c0 0.552 0.448 1 1 1h7v19.5z\"></path>\n",
       "<path d=\"M23 26h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 22h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 18h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "</symbol>\n",
       "</defs>\n",
       "</svg>\n",
       "<style>/* CSS stylesheet for displaying xarray objects in jupyterlab.\n",
       " *\n",
       " */\n",
       "\n",
       ":root {\n",
       "  --xr-font-color0: var(--jp-content-font-color0, rgba(0, 0, 0, 1));\n",
       "  --xr-font-color2: var(--jp-content-font-color2, rgba(0, 0, 0, 0.54));\n",
       "  --xr-font-color3: var(--jp-content-font-color3, rgba(0, 0, 0, 0.38));\n",
       "  --xr-border-color: var(--jp-border-color2, #e0e0e0);\n",
       "  --xr-disabled-color: var(--jp-layout-color3, #bdbdbd);\n",
       "  --xr-background-color: var(--jp-layout-color0, white);\n",
       "  --xr-background-color-row-even: var(--jp-layout-color1, white);\n",
       "  --xr-background-color-row-odd: var(--jp-layout-color2, #eeeeee);\n",
       "}\n",
       "\n",
       "html[theme=dark],\n",
       "body.vscode-dark {\n",
       "  --xr-font-color0: rgba(255, 255, 255, 1);\n",
       "  --xr-font-color2: rgba(255, 255, 255, 0.54);\n",
       "  --xr-font-color3: rgba(255, 255, 255, 0.38);\n",
       "  --xr-border-color: #1F1F1F;\n",
       "  --xr-disabled-color: #515151;\n",
       "  --xr-background-color: #111111;\n",
       "  --xr-background-color-row-even: #111111;\n",
       "  --xr-background-color-row-odd: #313131;\n",
       "}\n",
       "\n",
       ".xr-wrap {\n",
       "  display: block;\n",
       "  min-width: 300px;\n",
       "  max-width: 700px;\n",
       "}\n",
       "\n",
       ".xr-text-repr-fallback {\n",
       "  /* fallback to plain text repr when CSS is not injected (untrusted notebook) */\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-header {\n",
       "  padding-top: 6px;\n",
       "  padding-bottom: 6px;\n",
       "  margin-bottom: 4px;\n",
       "  border-bottom: solid 1px var(--xr-border-color);\n",
       "}\n",
       "\n",
       ".xr-header > div,\n",
       ".xr-header > ul {\n",
       "  display: inline;\n",
       "  margin-top: 0;\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-obj-type,\n",
       ".xr-array-name {\n",
       "  margin-left: 2px;\n",
       "  margin-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-obj-type {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-sections {\n",
       "  padding-left: 0 !important;\n",
       "  display: grid;\n",
       "  grid-template-columns: 150px auto auto 1fr 20px 20px;\n",
       "}\n",
       "\n",
       ".xr-section-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-section-item input {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-item input + label {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label {\n",
       "  cursor: pointer;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label:hover {\n",
       "  color: var(--xr-font-color0);\n",
       "}\n",
       "\n",
       ".xr-section-summary {\n",
       "  grid-column: 1;\n",
       "  color: var(--xr-font-color2);\n",
       "  font-weight: 500;\n",
       "}\n",
       "\n",
       ".xr-section-summary > span {\n",
       "  display: inline-block;\n",
       "  padding-left: 0.5em;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in + label:before {\n",
       "  display: inline-block;\n",
       "  content: '►';\n",
       "  font-size: 11px;\n",
       "  width: 15px;\n",
       "  text-align: center;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label:before {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label:before {\n",
       "  content: '▼';\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label > span {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-summary,\n",
       ".xr-section-inline-details {\n",
       "  padding-top: 4px;\n",
       "  padding-bottom: 4px;\n",
       "}\n",
       "\n",
       ".xr-section-inline-details {\n",
       "  grid-column: 2 / -1;\n",
       "}\n",
       "\n",
       ".xr-section-details {\n",
       "  display: none;\n",
       "  grid-column: 1 / -1;\n",
       "  margin-bottom: 5px;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked ~ .xr-section-details {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-array-wrap {\n",
       "  grid-column: 1 / -1;\n",
       "  display: grid;\n",
       "  grid-template-columns: 20px auto;\n",
       "}\n",
       "\n",
       ".xr-array-wrap > label {\n",
       "  grid-column: 1;\n",
       "  vertical-align: top;\n",
       "}\n",
       "\n",
       ".xr-preview {\n",
       "  color: var(--xr-font-color3);\n",
       "}\n",
       "\n",
       ".xr-array-preview,\n",
       ".xr-array-data {\n",
       "  padding: 0 5px !important;\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-array-data,\n",
       ".xr-array-in:checked ~ .xr-array-preview {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-array-in:checked ~ .xr-array-data,\n",
       ".xr-array-preview {\n",
       "  display: inline-block;\n",
       "}\n",
       "\n",
       ".xr-dim-list {\n",
       "  display: inline-block !important;\n",
       "  list-style: none;\n",
       "  padding: 0 !important;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list li {\n",
       "  display: inline-block;\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list:before {\n",
       "  content: '(';\n",
       "}\n",
       "\n",
       ".xr-dim-list:after {\n",
       "  content: ')';\n",
       "}\n",
       "\n",
       ".xr-dim-list li:not(:last-child):after {\n",
       "  content: ',';\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-has-index {\n",
       "  font-weight: bold;\n",
       "}\n",
       "\n",
       ".xr-var-list,\n",
       ".xr-var-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-var-item > div,\n",
       ".xr-var-item label,\n",
       ".xr-var-item > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-even);\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-var-item > .xr-var-name:hover span {\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-var-list > li:nth-child(odd) > div,\n",
       ".xr-var-list > li:nth-child(odd) > label,\n",
       ".xr-var-list > li:nth-child(odd) > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-odd);\n",
       "}\n",
       "\n",
       ".xr-var-name {\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-var-dims {\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-var-dtype {\n",
       "  grid-column: 3;\n",
       "  text-align: right;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-var-preview {\n",
       "  grid-column: 4;\n",
       "}\n",
       "\n",
       ".xr-var-name,\n",
       ".xr-var-dims,\n",
       ".xr-var-dtype,\n",
       ".xr-preview,\n",
       ".xr-attrs dt {\n",
       "  white-space: nowrap;\n",
       "  overflow: hidden;\n",
       "  text-overflow: ellipsis;\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-var-name:hover,\n",
       ".xr-var-dims:hover,\n",
       ".xr-var-dtype:hover,\n",
       ".xr-attrs dt:hover {\n",
       "  overflow: visible;\n",
       "  width: auto;\n",
       "  z-index: 1;\n",
       "}\n",
       "\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  display: none;\n",
       "  background-color: var(--xr-background-color) !important;\n",
       "  padding-bottom: 5px !important;\n",
       "}\n",
       "\n",
       ".xr-var-attrs-in:checked ~ .xr-var-attrs,\n",
       ".xr-var-data-in:checked ~ .xr-var-data {\n",
       "  display: block;\n",
       "}\n",
       "\n",
       ".xr-var-data > table {\n",
       "  float: right;\n",
       "}\n",
       "\n",
       ".xr-var-name span,\n",
       ".xr-var-data,\n",
       ".xr-attrs {\n",
       "  padding-left: 25px !important;\n",
       "}\n",
       "\n",
       ".xr-attrs,\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  grid-column: 1 / -1;\n",
       "}\n",
       "\n",
       "dl.xr-attrs {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  display: grid;\n",
       "  grid-template-columns: 125px auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt, dd {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  float: left;\n",
       "  padding-right: 10px;\n",
       "  width: auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt {\n",
       "  font-weight: normal;\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-attrs dt:hover span {\n",
       "  display: inline-block;\n",
       "  background: var(--xr-background-color);\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-attrs dd {\n",
       "  grid-column: 2;\n",
       "  white-space: pre-wrap;\n",
       "  word-break: break-all;\n",
       "}\n",
       "\n",
       ".xr-icon-database,\n",
       ".xr-icon-file-text2 {\n",
       "  display: inline-block;\n",
       "  vertical-align: middle;\n",
       "  width: 1em;\n",
       "  height: 1.5em !important;\n",
       "  stroke-width: 0;\n",
       "  stroke: currentColor;\n",
       "  fill: currentColor;\n",
       "}\n",
       "</style><pre class='xr-text-repr-fallback'>&lt;xarray.Dataset&gt;\n",
       "Dimensions:  (month: 36, year: 100)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 ... 28 29 30 31 32 33 34 35 36\n",
       "Data variables:\n",
       "    nino     (year, month) float64 -0.4072 -0.2024 -0.1039 ... 1.64 1.557 1.38</pre><div class='xr-wrap' hidden><div class='xr-header'><div class='xr-obj-type'>xarray.Dataset</div></div><ul class='xr-sections'><li class='xr-section-item'><input id='section-a876b67f-b5a7-4b70-a2db-1b10105d0103' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-a876b67f-b5a7-4b70-a2db-1b10105d0103' class='xr-section-summary'  title='Expand/collapse section'>Dimensions:</label><div class='xr-section-inline-details'><ul class='xr-dim-list'><li><span class='xr-has-index'>month</span>: 36</li><li><span class='xr-has-index'>year</span>: 100</li></ul></div><div class='xr-section-details'></div></li><li class='xr-section-item'><input id='section-459d39ea-8bf5-4440-b449-c1d660d5bd14' class='xr-section-summary-in' type='checkbox'  checked><label for='section-459d39ea-8bf5-4440-b449-c1d660d5bd14' class='xr-section-summary' >Coordinates: <span>(2)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>year</span></div><div class='xr-var-dims'>(year)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 ... 95 96 97 98 99 100</div><input id='attrs-c7b7c7fa-b8da-425a-b2b1-edf8a3d2f4e4' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-c7b7c7fa-b8da-425a-b2b1-edf8a3d2f4e4' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-8c807fb4-455e-4fa6-aada-75837bb593dd' class='xr-var-data-in' type='checkbox'><label for='data-8c807fb4-455e-4fa6-aada-75837bb593dd' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  1,   2,   3,   4,   5,   6,   7,   8,   9,  10,  11,  12,  13,  14,\n",
       "        15,  16,  17,  18,  19,  20,  21,  22,  23,  24,  25,  26,  27,  28,\n",
       "        29,  30,  31,  32,  33,  34,  35,  36,  37,  38,  39,  40,  41,  42,\n",
       "        43,  44,  45,  46,  47,  48,  49,  50,  51,  52,  53,  54,  55,  56,\n",
       "        57,  58,  59,  60,  61,  62,  63,  64,  65,  66,  67,  68,  69,  70,\n",
       "        71,  72,  73,  74,  75,  76,  77,  78,  79,  80,  81,  82,  83,  84,\n",
       "        85,  86,  87,  88,  89,  90,  91,  92,  93,  94,  95,  96,  97,  98,\n",
       "        99, 100], dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>month</span></div><div class='xr-var-dims'>(month)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 7 ... 31 32 33 34 35 36</div><input id='attrs-74735555-5001-47d0-b967-db8135c3d205' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-74735555-5001-47d0-b967-db8135c3d205' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-3e0be2ad-6332-41e1-84f8-2b576299f03b' class='xr-var-data-in' type='checkbox'><label for='data-3e0be2ad-6332-41e1-84f8-2b576299f03b' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12, 13, 14, 15, 16, 17, 18,\n",
       "       19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36],\n",
       "      dtype=int32)</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-b34b907c-5548-45d6-8f7e-65600346b762' class='xr-section-summary-in' type='checkbox'  checked><label for='section-b34b907c-5548-45d6-8f7e-65600346b762' class='xr-section-summary' >Data variables: <span>(1)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span>nino</span></div><div class='xr-var-dims'>(year, month)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-eafd5c10-40bb-4d65-beb2-6d2f6c690054' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-eafd5c10-40bb-4d65-beb2-6d2f6c690054' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-895cdcc5-e45b-4323-821b-f0bac8f02dd3' class='xr-var-data-in' type='checkbox'><label for='data-895cdcc5-e45b-4323-821b-f0bac8f02dd3' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[-0.407207, -0.202444, -0.103861, ...,  0.027556,  0.011619, -0.04931 ],\n",
       "       [ 0.066972,  0.009991, -0.001648, ..., -0.311925, -0.360468, -0.326235],\n",
       "       [-0.732018, -0.72509 , -0.584168, ..., -0.357212, -0.043384,  0.087158],\n",
       "       ...,\n",
       "       [-0.679456, -0.799537, -0.786814, ..., -0.976172, -1.176811, -1.365284],\n",
       "       [ 0.697723,  0.588552,  0.368555, ..., -0.815693, -0.696027, -0.561618],\n",
       "       [ 0.210419,  0.012162, -0.186154, ...,  1.63955 ,  1.557064,  1.380289]])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-232f1826-b7fc-46eb-88c9-183996314362' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-232f1826-b7fc-46eb-88c9-183996314362' class='xr-section-summary'  title='Expand/collapse section'>Attributes: <span>(0)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><dl class='xr-attrs'></dl></div></li></ul></div></div>"
      ],
      "text/plain": [
       "<xarray.Dataset>\n",
       "Dimensions:  (month: 36, year: 100)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 ... 28 29 30 31 32 33 34 35 36\n",
       "Data variables:\n",
       "    nino     (year, month) float64 ..."
      ]
     },
     "execution_count": 375,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "d=nc.Dataset('../tcdata/enso_round1_train_20210201/SODA_label.nc')\n",
    "D= xr.open_dataset(xr.backends.NetCDF4DataStore(d))\n",
    "D"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 377,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div><svg style=\"position: absolute; width: 0; height: 0; overflow: hidden\">\n",
       "<defs>\n",
       "<symbol id=\"icon-database\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M16 0c-8.837 0-16 2.239-16 5v4c0 2.761 7.163 5 16 5s16-2.239 16-5v-4c0-2.761-7.163-5-16-5z\"></path>\n",
       "<path d=\"M16 17c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "<path d=\"M16 26c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "</symbol>\n",
       "<symbol id=\"icon-file-text2\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M28.681 7.159c-0.694-0.947-1.662-2.053-2.724-3.116s-2.169-2.030-3.116-2.724c-1.612-1.182-2.393-1.319-2.841-1.319h-15.5c-1.378 0-2.5 1.121-2.5 2.5v27c0 1.378 1.122 2.5 2.5 2.5h23c1.378 0 2.5-1.122 2.5-2.5v-19.5c0-0.448-0.137-1.23-1.319-2.841zM24.543 5.457c0.959 0.959 1.712 1.825 2.268 2.543h-4.811v-4.811c0.718 0.556 1.584 1.309 2.543 2.268zM28 29.5c0 0.271-0.229 0.5-0.5 0.5h-23c-0.271 0-0.5-0.229-0.5-0.5v-27c0-0.271 0.229-0.5 0.5-0.5 0 0 15.499-0 15.5 0v7c0 0.552 0.448 1 1 1h7v19.5z\"></path>\n",
       "<path d=\"M23 26h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 22h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 18h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "</symbol>\n",
       "</defs>\n",
       "</svg>\n",
       "<style>/* CSS stylesheet for displaying xarray objects in jupyterlab.\n",
       " *\n",
       " */\n",
       "\n",
       ":root {\n",
       "  --xr-font-color0: var(--jp-content-font-color0, rgba(0, 0, 0, 1));\n",
       "  --xr-font-color2: var(--jp-content-font-color2, rgba(0, 0, 0, 0.54));\n",
       "  --xr-font-color3: var(--jp-content-font-color3, rgba(0, 0, 0, 0.38));\n",
       "  --xr-border-color: var(--jp-border-color2, #e0e0e0);\n",
       "  --xr-disabled-color: var(--jp-layout-color3, #bdbdbd);\n",
       "  --xr-background-color: var(--jp-layout-color0, white);\n",
       "  --xr-background-color-row-even: var(--jp-layout-color1, white);\n",
       "  --xr-background-color-row-odd: var(--jp-layout-color2, #eeeeee);\n",
       "}\n",
       "\n",
       "html[theme=dark],\n",
       "body.vscode-dark {\n",
       "  --xr-font-color0: rgba(255, 255, 255, 1);\n",
       "  --xr-font-color2: rgba(255, 255, 255, 0.54);\n",
       "  --xr-font-color3: rgba(255, 255, 255, 0.38);\n",
       "  --xr-border-color: #1F1F1F;\n",
       "  --xr-disabled-color: #515151;\n",
       "  --xr-background-color: #111111;\n",
       "  --xr-background-color-row-even: #111111;\n",
       "  --xr-background-color-row-odd: #313131;\n",
       "}\n",
       "\n",
       ".xr-wrap {\n",
       "  display: block;\n",
       "  min-width: 300px;\n",
       "  max-width: 700px;\n",
       "}\n",
       "\n",
       ".xr-text-repr-fallback {\n",
       "  /* fallback to plain text repr when CSS is not injected (untrusted notebook) */\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-header {\n",
       "  padding-top: 6px;\n",
       "  padding-bottom: 6px;\n",
       "  margin-bottom: 4px;\n",
       "  border-bottom: solid 1px var(--xr-border-color);\n",
       "}\n",
       "\n",
       ".xr-header > div,\n",
       ".xr-header > ul {\n",
       "  display: inline;\n",
       "  margin-top: 0;\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-obj-type,\n",
       ".xr-array-name {\n",
       "  margin-left: 2px;\n",
       "  margin-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-obj-type {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-sections {\n",
       "  padding-left: 0 !important;\n",
       "  display: grid;\n",
       "  grid-template-columns: 150px auto auto 1fr 20px 20px;\n",
       "}\n",
       "\n",
       ".xr-section-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-section-item input {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-item input + label {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label {\n",
       "  cursor: pointer;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label:hover {\n",
       "  color: var(--xr-font-color0);\n",
       "}\n",
       "\n",
       ".xr-section-summary {\n",
       "  grid-column: 1;\n",
       "  color: var(--xr-font-color2);\n",
       "  font-weight: 500;\n",
       "}\n",
       "\n",
       ".xr-section-summary > span {\n",
       "  display: inline-block;\n",
       "  padding-left: 0.5em;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in + label:before {\n",
       "  display: inline-block;\n",
       "  content: '►';\n",
       "  font-size: 11px;\n",
       "  width: 15px;\n",
       "  text-align: center;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label:before {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label:before {\n",
       "  content: '▼';\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label > span {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-summary,\n",
       ".xr-section-inline-details {\n",
       "  padding-top: 4px;\n",
       "  padding-bottom: 4px;\n",
       "}\n",
       "\n",
       ".xr-section-inline-details {\n",
       "  grid-column: 2 / -1;\n",
       "}\n",
       "\n",
       ".xr-section-details {\n",
       "  display: none;\n",
       "  grid-column: 1 / -1;\n",
       "  margin-bottom: 5px;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked ~ .xr-section-details {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-array-wrap {\n",
       "  grid-column: 1 / -1;\n",
       "  display: grid;\n",
       "  grid-template-columns: 20px auto;\n",
       "}\n",
       "\n",
       ".xr-array-wrap > label {\n",
       "  grid-column: 1;\n",
       "  vertical-align: top;\n",
       "}\n",
       "\n",
       ".xr-preview {\n",
       "  color: var(--xr-font-color3);\n",
       "}\n",
       "\n",
       ".xr-array-preview,\n",
       ".xr-array-data {\n",
       "  padding: 0 5px !important;\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-array-data,\n",
       ".xr-array-in:checked ~ .xr-array-preview {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-array-in:checked ~ .xr-array-data,\n",
       ".xr-array-preview {\n",
       "  display: inline-block;\n",
       "}\n",
       "\n",
       ".xr-dim-list {\n",
       "  display: inline-block !important;\n",
       "  list-style: none;\n",
       "  padding: 0 !important;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list li {\n",
       "  display: inline-block;\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list:before {\n",
       "  content: '(';\n",
       "}\n",
       "\n",
       ".xr-dim-list:after {\n",
       "  content: ')';\n",
       "}\n",
       "\n",
       ".xr-dim-list li:not(:last-child):after {\n",
       "  content: ',';\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-has-index {\n",
       "  font-weight: bold;\n",
       "}\n",
       "\n",
       ".xr-var-list,\n",
       ".xr-var-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-var-item > div,\n",
       ".xr-var-item label,\n",
       ".xr-var-item > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-even);\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-var-item > .xr-var-name:hover span {\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-var-list > li:nth-child(odd) > div,\n",
       ".xr-var-list > li:nth-child(odd) > label,\n",
       ".xr-var-list > li:nth-child(odd) > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-odd);\n",
       "}\n",
       "\n",
       ".xr-var-name {\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-var-dims {\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-var-dtype {\n",
       "  grid-column: 3;\n",
       "  text-align: right;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-var-preview {\n",
       "  grid-column: 4;\n",
       "}\n",
       "\n",
       ".xr-var-name,\n",
       ".xr-var-dims,\n",
       ".xr-var-dtype,\n",
       ".xr-preview,\n",
       ".xr-attrs dt {\n",
       "  white-space: nowrap;\n",
       "  overflow: hidden;\n",
       "  text-overflow: ellipsis;\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-var-name:hover,\n",
       ".xr-var-dims:hover,\n",
       ".xr-var-dtype:hover,\n",
       ".xr-attrs dt:hover {\n",
       "  overflow: visible;\n",
       "  width: auto;\n",
       "  z-index: 1;\n",
       "}\n",
       "\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  display: none;\n",
       "  background-color: var(--xr-background-color) !important;\n",
       "  padding-bottom: 5px !important;\n",
       "}\n",
       "\n",
       ".xr-var-attrs-in:checked ~ .xr-var-attrs,\n",
       ".xr-var-data-in:checked ~ .xr-var-data {\n",
       "  display: block;\n",
       "}\n",
       "\n",
       ".xr-var-data > table {\n",
       "  float: right;\n",
       "}\n",
       "\n",
       ".xr-var-name span,\n",
       ".xr-var-data,\n",
       ".xr-attrs {\n",
       "  padding-left: 25px !important;\n",
       "}\n",
       "\n",
       ".xr-attrs,\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  grid-column: 1 / -1;\n",
       "}\n",
       "\n",
       "dl.xr-attrs {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  display: grid;\n",
       "  grid-template-columns: 125px auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt, dd {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  float: left;\n",
       "  padding-right: 10px;\n",
       "  width: auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt {\n",
       "  font-weight: normal;\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-attrs dt:hover span {\n",
       "  display: inline-block;\n",
       "  background: var(--xr-background-color);\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-attrs dd {\n",
       "  grid-column: 2;\n",
       "  white-space: pre-wrap;\n",
       "  word-break: break-all;\n",
       "}\n",
       "\n",
       ".xr-icon-database,\n",
       ".xr-icon-file-text2 {\n",
       "  display: inline-block;\n",
       "  vertical-align: middle;\n",
       "  width: 1em;\n",
       "  height: 1.5em !important;\n",
       "  stroke-width: 0;\n",
       "  stroke: currentColor;\n",
       "  fill: currentColor;\n",
       "}\n",
       "</style><pre class='xr-text-repr-fallback'>&lt;xarray.Dataset&gt;\n",
       "Dimensions:  (lat: 24, lon: 72, month: 36, year: 100)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 ... 28 29 30 31 32 33 34 35 36\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "Data variables:\n",
       "    sst      (year, month, lat, lon) float32 ...\n",
       "    t300     (year, month, lat, lon) float32 ...\n",
       "    ua       (year, month, lat, lon) float64 ...\n",
       "    va       (year, month, lat, lon) float64 ...\n",
       "    nino     (year, month) float64 -0.4072 -0.2024 -0.1039 ... 1.64 1.557 1.38</pre><div class='xr-wrap' hidden><div class='xr-header'><div class='xr-obj-type'>xarray.Dataset</div></div><ul class='xr-sections'><li class='xr-section-item'><input id='section-2e5ae932-2912-4eb5-9968-1af15d16fbe3' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-2e5ae932-2912-4eb5-9968-1af15d16fbe3' class='xr-section-summary'  title='Expand/collapse section'>Dimensions:</label><div class='xr-section-inline-details'><ul class='xr-dim-list'><li><span class='xr-has-index'>lat</span>: 24</li><li><span class='xr-has-index'>lon</span>: 72</li><li><span class='xr-has-index'>month</span>: 36</li><li><span class='xr-has-index'>year</span>: 100</li></ul></div><div class='xr-section-details'></div></li><li class='xr-section-item'><input id='section-3ce7ebac-3465-46fc-b173-4fb37c362b87' class='xr-section-summary-in' type='checkbox'  checked><label for='section-3ce7ebac-3465-46fc-b173-4fb37c362b87' class='xr-section-summary' >Coordinates: <span>(4)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>year</span></div><div class='xr-var-dims'>(year)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 ... 95 96 97 98 99 100</div><input id='attrs-80899a72-79b4-483c-95a0-6aed8398633c' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-80899a72-79b4-483c-95a0-6aed8398633c' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-2c216cb1-a6bb-4832-abbf-4e97d9155595' class='xr-var-data-in' type='checkbox'><label for='data-2c216cb1-a6bb-4832-abbf-4e97d9155595' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  1,   2,   3,   4,   5,   6,   7,   8,   9,  10,  11,  12,  13,  14,\n",
       "        15,  16,  17,  18,  19,  20,  21,  22,  23,  24,  25,  26,  27,  28,\n",
       "        29,  30,  31,  32,  33,  34,  35,  36,  37,  38,  39,  40,  41,  42,\n",
       "        43,  44,  45,  46,  47,  48,  49,  50,  51,  52,  53,  54,  55,  56,\n",
       "        57,  58,  59,  60,  61,  62,  63,  64,  65,  66,  67,  68,  69,  70,\n",
       "        71,  72,  73,  74,  75,  76,  77,  78,  79,  80,  81,  82,  83,  84,\n",
       "        85,  86,  87,  88,  89,  90,  91,  92,  93,  94,  95,  96,  97,  98,\n",
       "        99, 100], dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>month</span></div><div class='xr-var-dims'>(month)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 7 ... 31 32 33 34 35 36</div><input id='attrs-dda571cd-2ad2-4b51-88cb-857ee8a3e6ca' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-dda571cd-2ad2-4b51-88cb-857ee8a3e6ca' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-9d5ac26e-bec5-4ba8-9de9-c069653d915d' class='xr-var-data-in' type='checkbox'><label for='data-9d5ac26e-bec5-4ba8-9de9-c069653d915d' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12, 13, 14, 15, 16, 17, 18,\n",
       "       19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36],\n",
       "      dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lat</span></div><div class='xr-var-dims'>(lat)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-55.0 -50.0 -45.0 ... 55.0 60.0</div><input id='attrs-15ff2967-f9f7-48cb-9067-aefc6908a802' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-15ff2967-f9f7-48cb-9067-aefc6908a802' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-a19a0b07-93fe-4f0e-b89d-5c9491774e55' class='xr-var-data-in' type='checkbox'><label for='data-a19a0b07-93fe-4f0e-b89d-5c9491774e55' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([-55., -50., -45., -40., -35., -30., -25., -20., -15., -10.,  -5.,   0.,\n",
       "         5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,  60.])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lon</span></div><div class='xr-var-dims'>(lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.0 5.0 10.0 ... 345.0 350.0 355.0</div><input id='attrs-38c6b9a3-cf6c-4e26-9b10-c6d94a0da9ee' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-38c6b9a3-cf6c-4e26-9b10-c6d94a0da9ee' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-56225bd7-3da5-4828-93de-04e97cb61954' class='xr-var-data-in' type='checkbox'><label for='data-56225bd7-3da5-4828-93de-04e97cb61954' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  0.,   5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,\n",
       "        60.,  65.,  70.,  75.,  80.,  85.,  90.,  95., 100., 105., 110., 115.,\n",
       "       120., 125., 130., 135., 140., 145., 150., 155., 160., 165., 170., 175.,\n",
       "       180., 185., 190., 195., 200., 205., 210., 215., 220., 225., 230., 235.,\n",
       "       240., 245., 250., 255., 260., 265., 270., 275., 280., 285., 290., 295.,\n",
       "       300., 305., 310., 315., 320., 325., 330., 335., 340., 345., 350., 355.])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-7fea4132-ba11-4c25-8c9b-af4dd3238a7c' class='xr-section-summary-in' type='checkbox'  checked><label for='section-7fea4132-ba11-4c25-8c9b-af4dd3238a7c' class='xr-section-summary' >Data variables: <span>(5)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span>sst</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-b8061d98-c412-4366-bc58-be50720ee962' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-b8061d98-c412-4366-bc58-be50720ee962' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-880c0b8b-4351-42f1-8484-58dc1af9733e' class='xr-var-data-in' type='checkbox'><label for='data-880c0b8b-4351-42f1-8484-58dc1af9733e' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[6220800 values with dtype=float32]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>t300</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-338b0ee8-7c69-4486-a0cb-e41022264178' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-338b0ee8-7c69-4486-a0cb-e41022264178' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-3a0c5b35-ebfd-4ef9-8f84-1f9b23fc6fa3' class='xr-var-data-in' type='checkbox'><label for='data-3a0c5b35-ebfd-4ef9-8f84-1f9b23fc6fa3' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[6220800 values with dtype=float32]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>ua</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-8fc0e388-dbc3-4a45-bd00-4349d71ed749' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-8fc0e388-dbc3-4a45-bd00-4349d71ed749' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-825fe525-809a-44e4-973a-5ccb117d9e12' class='xr-var-data-in' type='checkbox'><label for='data-825fe525-809a-44e4-973a-5ccb117d9e12' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[6220800 values with dtype=float64]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>va</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-83beb67a-e97e-41b8-8e03-1b7dedcc083f' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-83beb67a-e97e-41b8-8e03-1b7dedcc083f' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-efb2fb6e-4687-4502-b9bb-716b8b29a446' class='xr-var-data-in' type='checkbox'><label for='data-efb2fb6e-4687-4502-b9bb-716b8b29a446' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[6220800 values with dtype=float64]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>nino</span></div><div class='xr-var-dims'>(year, month)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-0.4072 -0.2024 ... 1.557 1.38</div><input id='attrs-fdbd0805-994e-44fc-995f-7642b0263b72' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-fdbd0805-994e-44fc-995f-7642b0263b72' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-d0919da7-8d9c-4c62-8a4a-441e8e9c253e' class='xr-var-data-in' type='checkbox'><label for='data-d0919da7-8d9c-4c62-8a4a-441e8e9c253e' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[-0.40720701, -0.20244436, -0.10386104, ...,  0.02755602,\n",
       "         0.011619  , -0.04931002],\n",
       "       [ 0.06697161,  0.00999126, -0.00164753, ..., -0.31192511,\n",
       "        -0.36046785, -0.32623523],\n",
       "       [-0.73201811, -0.72508991, -0.58416802, ..., -0.3572121 ,\n",
       "        -0.04338433,  0.08715798],\n",
       "       ...,\n",
       "       [-0.679456  , -0.79953653, -0.78681421, ..., -0.97617215,\n",
       "        -1.17681098, -1.36528361],\n",
       "       [ 0.69772309,  0.58855242,  0.36855501, ..., -0.81569326,\n",
       "        -0.69602704, -0.56161773],\n",
       "       [ 0.21041885,  0.01216245, -0.18615368, ...,  1.63954973,\n",
       "         1.55706418,  1.38028944]])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-26b78898-9d2e-4f76-baef-82113e0d8f18' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-26b78898-9d2e-4f76-baef-82113e0d8f18' class='xr-section-summary'  title='Expand/collapse section'>Attributes: <span>(0)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><dl class='xr-attrs'></dl></div></li></ul></div></div>"
      ],
      "text/plain": [
       "<xarray.Dataset>\n",
       "Dimensions:  (lat: 24, lon: 72, month: 36, year: 100)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 ... 28 29 30 31 32 33 34 35 36\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "Data variables:\n",
       "    sst      (year, month, lat, lon) float32 ...\n",
       "    t300     (year, month, lat, lon) float32 ...\n",
       "    ua       (year, month, lat, lon) float64 ...\n",
       "    va       (year, month, lat, lon) float64 ...\n",
       "    nino     (year, month) float64 -0.4072 -0.2024 -0.1039 ... 1.64 1.557 1.38"
      ]
     },
     "execution_count": 377,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "SODA=C\n",
    "SODA['nino']=(('year','month'),D.nino)\n",
    "SODA"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 382,
   "metadata": {},
   "outputs": [],
   "source": [
    "SODA=SODA.drop_sel(month=np.arange(13,37))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 385,
   "metadata": {},
   "outputs": [],
   "source": [
    "SODA=SODA.assign_coords(mode=(\"mode\",10000*(SODA.year>0)))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 388,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div><svg style=\"position: absolute; width: 0; height: 0; overflow: hidden\">\n",
       "<defs>\n",
       "<symbol id=\"icon-database\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M16 0c-8.837 0-16 2.239-16 5v4c0 2.761 7.163 5 16 5s16-2.239 16-5v-4c0-2.761-7.163-5-16-5z\"></path>\n",
       "<path d=\"M16 17c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "<path d=\"M16 26c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "</symbol>\n",
       "<symbol id=\"icon-file-text2\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M28.681 7.159c-0.694-0.947-1.662-2.053-2.724-3.116s-2.169-2.030-3.116-2.724c-1.612-1.182-2.393-1.319-2.841-1.319h-15.5c-1.378 0-2.5 1.121-2.5 2.5v27c0 1.378 1.122 2.5 2.5 2.5h23c1.378 0 2.5-1.122 2.5-2.5v-19.5c0-0.448-0.137-1.23-1.319-2.841zM24.543 5.457c0.959 0.959 1.712 1.825 2.268 2.543h-4.811v-4.811c0.718 0.556 1.584 1.309 2.543 2.268zM28 29.5c0 0.271-0.229 0.5-0.5 0.5h-23c-0.271 0-0.5-0.229-0.5-0.5v-27c0-0.271 0.229-0.5 0.5-0.5 0 0 15.499-0 15.5 0v7c0 0.552 0.448 1 1 1h7v19.5z\"></path>\n",
       "<path d=\"M23 26h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 22h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 18h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "</symbol>\n",
       "</defs>\n",
       "</svg>\n",
       "<style>/* CSS stylesheet for displaying xarray objects in jupyterlab.\n",
       " *\n",
       " */\n",
       "\n",
       ":root {\n",
       "  --xr-font-color0: var(--jp-content-font-color0, rgba(0, 0, 0, 1));\n",
       "  --xr-font-color2: var(--jp-content-font-color2, rgba(0, 0, 0, 0.54));\n",
       "  --xr-font-color3: var(--jp-content-font-color3, rgba(0, 0, 0, 0.38));\n",
       "  --xr-border-color: var(--jp-border-color2, #e0e0e0);\n",
       "  --xr-disabled-color: var(--jp-layout-color3, #bdbdbd);\n",
       "  --xr-background-color: var(--jp-layout-color0, white);\n",
       "  --xr-background-color-row-even: var(--jp-layout-color1, white);\n",
       "  --xr-background-color-row-odd: var(--jp-layout-color2, #eeeeee);\n",
       "}\n",
       "\n",
       "html[theme=dark],\n",
       "body.vscode-dark {\n",
       "  --xr-font-color0: rgba(255, 255, 255, 1);\n",
       "  --xr-font-color2: rgba(255, 255, 255, 0.54);\n",
       "  --xr-font-color3: rgba(255, 255, 255, 0.38);\n",
       "  --xr-border-color: #1F1F1F;\n",
       "  --xr-disabled-color: #515151;\n",
       "  --xr-background-color: #111111;\n",
       "  --xr-background-color-row-even: #111111;\n",
       "  --xr-background-color-row-odd: #313131;\n",
       "}\n",
       "\n",
       ".xr-wrap {\n",
       "  display: block;\n",
       "  min-width: 300px;\n",
       "  max-width: 700px;\n",
       "}\n",
       "\n",
       ".xr-text-repr-fallback {\n",
       "  /* fallback to plain text repr when CSS is not injected (untrusted notebook) */\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-header {\n",
       "  padding-top: 6px;\n",
       "  padding-bottom: 6px;\n",
       "  margin-bottom: 4px;\n",
       "  border-bottom: solid 1px var(--xr-border-color);\n",
       "}\n",
       "\n",
       ".xr-header > div,\n",
       ".xr-header > ul {\n",
       "  display: inline;\n",
       "  margin-top: 0;\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-obj-type,\n",
       ".xr-array-name {\n",
       "  margin-left: 2px;\n",
       "  margin-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-obj-type {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-sections {\n",
       "  padding-left: 0 !important;\n",
       "  display: grid;\n",
       "  grid-template-columns: 150px auto auto 1fr 20px 20px;\n",
       "}\n",
       "\n",
       ".xr-section-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-section-item input {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-item input + label {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label {\n",
       "  cursor: pointer;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label:hover {\n",
       "  color: var(--xr-font-color0);\n",
       "}\n",
       "\n",
       ".xr-section-summary {\n",
       "  grid-column: 1;\n",
       "  color: var(--xr-font-color2);\n",
       "  font-weight: 500;\n",
       "}\n",
       "\n",
       ".xr-section-summary > span {\n",
       "  display: inline-block;\n",
       "  padding-left: 0.5em;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in + label:before {\n",
       "  display: inline-block;\n",
       "  content: '►';\n",
       "  font-size: 11px;\n",
       "  width: 15px;\n",
       "  text-align: center;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label:before {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label:before {\n",
       "  content: '▼';\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label > span {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-summary,\n",
       ".xr-section-inline-details {\n",
       "  padding-top: 4px;\n",
       "  padding-bottom: 4px;\n",
       "}\n",
       "\n",
       ".xr-section-inline-details {\n",
       "  grid-column: 2 / -1;\n",
       "}\n",
       "\n",
       ".xr-section-details {\n",
       "  display: none;\n",
       "  grid-column: 1 / -1;\n",
       "  margin-bottom: 5px;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked ~ .xr-section-details {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-array-wrap {\n",
       "  grid-column: 1 / -1;\n",
       "  display: grid;\n",
       "  grid-template-columns: 20px auto;\n",
       "}\n",
       "\n",
       ".xr-array-wrap > label {\n",
       "  grid-column: 1;\n",
       "  vertical-align: top;\n",
       "}\n",
       "\n",
       ".xr-preview {\n",
       "  color: var(--xr-font-color3);\n",
       "}\n",
       "\n",
       ".xr-array-preview,\n",
       ".xr-array-data {\n",
       "  padding: 0 5px !important;\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-array-data,\n",
       ".xr-array-in:checked ~ .xr-array-preview {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-array-in:checked ~ .xr-array-data,\n",
       ".xr-array-preview {\n",
       "  display: inline-block;\n",
       "}\n",
       "\n",
       ".xr-dim-list {\n",
       "  display: inline-block !important;\n",
       "  list-style: none;\n",
       "  padding: 0 !important;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list li {\n",
       "  display: inline-block;\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list:before {\n",
       "  content: '(';\n",
       "}\n",
       "\n",
       ".xr-dim-list:after {\n",
       "  content: ')';\n",
       "}\n",
       "\n",
       ".xr-dim-list li:not(:last-child):after {\n",
       "  content: ',';\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-has-index {\n",
       "  font-weight: bold;\n",
       "}\n",
       "\n",
       ".xr-var-list,\n",
       ".xr-var-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-var-item > div,\n",
       ".xr-var-item label,\n",
       ".xr-var-item > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-even);\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-var-item > .xr-var-name:hover span {\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-var-list > li:nth-child(odd) > div,\n",
       ".xr-var-list > li:nth-child(odd) > label,\n",
       ".xr-var-list > li:nth-child(odd) > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-odd);\n",
       "}\n",
       "\n",
       ".xr-var-name {\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-var-dims {\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-var-dtype {\n",
       "  grid-column: 3;\n",
       "  text-align: right;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-var-preview {\n",
       "  grid-column: 4;\n",
       "}\n",
       "\n",
       ".xr-var-name,\n",
       ".xr-var-dims,\n",
       ".xr-var-dtype,\n",
       ".xr-preview,\n",
       ".xr-attrs dt {\n",
       "  white-space: nowrap;\n",
       "  overflow: hidden;\n",
       "  text-overflow: ellipsis;\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-var-name:hover,\n",
       ".xr-var-dims:hover,\n",
       ".xr-var-dtype:hover,\n",
       ".xr-attrs dt:hover {\n",
       "  overflow: visible;\n",
       "  width: auto;\n",
       "  z-index: 1;\n",
       "}\n",
       "\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  display: none;\n",
       "  background-color: var(--xr-background-color) !important;\n",
       "  padding-bottom: 5px !important;\n",
       "}\n",
       "\n",
       ".xr-var-attrs-in:checked ~ .xr-var-attrs,\n",
       ".xr-var-data-in:checked ~ .xr-var-data {\n",
       "  display: block;\n",
       "}\n",
       "\n",
       ".xr-var-data > table {\n",
       "  float: right;\n",
       "}\n",
       "\n",
       ".xr-var-name span,\n",
       ".xr-var-data,\n",
       ".xr-attrs {\n",
       "  padding-left: 25px !important;\n",
       "}\n",
       "\n",
       ".xr-attrs,\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  grid-column: 1 / -1;\n",
       "}\n",
       "\n",
       "dl.xr-attrs {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  display: grid;\n",
       "  grid-template-columns: 125px auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt, dd {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  float: left;\n",
       "  padding-right: 10px;\n",
       "  width: auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt {\n",
       "  font-weight: normal;\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-attrs dt:hover span {\n",
       "  display: inline-block;\n",
       "  background: var(--xr-background-color);\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-attrs dd {\n",
       "  grid-column: 2;\n",
       "  white-space: pre-wrap;\n",
       "  word-break: break-all;\n",
       "}\n",
       "\n",
       ".xr-icon-database,\n",
       ".xr-icon-file-text2 {\n",
       "  display: inline-block;\n",
       "  vertical-align: middle;\n",
       "  width: 1em;\n",
       "  height: 1.5em !important;\n",
       "  stroke-width: 0;\n",
       "  stroke: currentColor;\n",
       "  fill: currentColor;\n",
       "}\n",
       "</style><pre class='xr-text-repr-fallback'>&lt;xarray.Dataset&gt;\n",
       "Dimensions:  (lat: 24, lon: 72, mode: 100, month: 12, year: 100)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 11 12\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "  * mode     (mode) int64 10000 10000 10000 10000 ... 10000 10000 10000 10000\n",
       "    time     (year, month) int32 1 2 3 4 5 6 7 ... 1195 1196 1197 1198 1199 1200\n",
       "Data variables:\n",
       "    sst      (year, month, lat, lon) float32 ...\n",
       "    t300     (year, month, lat, lon) float32 ...\n",
       "    ua       (year, month, lat, lon) float64 ...\n",
       "    va       (year, month, lat, lon) float64 ...\n",
       "    nino     (year, month) float64 -0.4072 -0.2024 -0.1039 ... -1.177 -1.365</pre><div class='xr-wrap' hidden><div class='xr-header'><div class='xr-obj-type'>xarray.Dataset</div></div><ul class='xr-sections'><li class='xr-section-item'><input id='section-a96994ea-ae84-42c5-82f5-360cfcf4d0a7' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-a96994ea-ae84-42c5-82f5-360cfcf4d0a7' class='xr-section-summary'  title='Expand/collapse section'>Dimensions:</label><div class='xr-section-inline-details'><ul class='xr-dim-list'><li><span class='xr-has-index'>lat</span>: 24</li><li><span class='xr-has-index'>lon</span>: 72</li><li><span class='xr-has-index'>mode</span>: 100</li><li><span class='xr-has-index'>month</span>: 12</li><li><span class='xr-has-index'>year</span>: 100</li></ul></div><div class='xr-section-details'></div></li><li class='xr-section-item'><input id='section-d6dc3998-9e14-4e0b-9626-64b79cac378b' class='xr-section-summary-in' type='checkbox'  checked><label for='section-d6dc3998-9e14-4e0b-9626-64b79cac378b' class='xr-section-summary' >Coordinates: <span>(6)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>year</span></div><div class='xr-var-dims'>(year)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 ... 95 96 97 98 99 100</div><input id='attrs-dc879d0d-af95-4db8-aa99-27bc85d59d58' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-dc879d0d-af95-4db8-aa99-27bc85d59d58' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-c63b277e-6d90-4c88-b90e-d650a678f367' class='xr-var-data-in' type='checkbox'><label for='data-c63b277e-6d90-4c88-b90e-d650a678f367' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  1,   2,   3,   4,   5,   6,   7,   8,   9,  10,  11,  12,  13,  14,\n",
       "        15,  16,  17,  18,  19,  20,  21,  22,  23,  24,  25,  26,  27,  28,\n",
       "        29,  30,  31,  32,  33,  34,  35,  36,  37,  38,  39,  40,  41,  42,\n",
       "        43,  44,  45,  46,  47,  48,  49,  50,  51,  52,  53,  54,  55,  56,\n",
       "        57,  58,  59,  60,  61,  62,  63,  64,  65,  66,  67,  68,  69,  70,\n",
       "        71,  72,  73,  74,  75,  76,  77,  78,  79,  80,  81,  82,  83,  84,\n",
       "        85,  86,  87,  88,  89,  90,  91,  92,  93,  94,  95,  96,  97,  98,\n",
       "        99, 100], dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>month</span></div><div class='xr-var-dims'>(month)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 7 8 9 10 11 12</div><input id='attrs-db942d3c-4963-402a-b88f-08f95f2c6522' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-db942d3c-4963-402a-b88f-08f95f2c6522' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-8160915a-3dee-48b9-b5c7-e66471d04609' class='xr-var-data-in' type='checkbox'><label for='data-8160915a-3dee-48b9-b5c7-e66471d04609' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12], dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lat</span></div><div class='xr-var-dims'>(lat)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-55.0 -50.0 -45.0 ... 55.0 60.0</div><input id='attrs-55d86e0d-35ef-4de2-b964-d3e6b3003b2f' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-55d86e0d-35ef-4de2-b964-d3e6b3003b2f' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-ae55c9d6-474e-4d17-8a8c-e1b69066d248' class='xr-var-data-in' type='checkbox'><label for='data-ae55c9d6-474e-4d17-8a8c-e1b69066d248' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([-55., -50., -45., -40., -35., -30., -25., -20., -15., -10.,  -5.,   0.,\n",
       "         5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,  60.])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lon</span></div><div class='xr-var-dims'>(lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.0 5.0 10.0 ... 345.0 350.0 355.0</div><input id='attrs-1dd5a3d2-d900-4309-96d0-1ef0858b87bf' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-1dd5a3d2-d900-4309-96d0-1ef0858b87bf' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-035fc5df-506e-45ac-8927-1ab592ef0d65' class='xr-var-data-in' type='checkbox'><label for='data-035fc5df-506e-45ac-8927-1ab592ef0d65' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  0.,   5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,\n",
       "        60.,  65.,  70.,  75.,  80.,  85.,  90.,  95., 100., 105., 110., 115.,\n",
       "       120., 125., 130., 135., 140., 145., 150., 155., 160., 165., 170., 175.,\n",
       "       180., 185., 190., 195., 200., 205., 210., 215., 220., 225., 230., 235.,\n",
       "       240., 245., 250., 255., 260., 265., 270., 275., 280., 285., 290., 295.,\n",
       "       300., 305., 310., 315., 320., 325., 330., 335., 340., 345., 350., 355.])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>mode</span></div><div class='xr-var-dims'>(mode)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>10000 10000 10000 ... 10000 10000</div><input id='attrs-f389b4f5-b727-4b31-bb2c-4dee5ed7dd42' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-f389b4f5-b727-4b31-bb2c-4dee5ed7dd42' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-49708d7c-b454-4a83-9d7a-93c7c082f538' class='xr-var-data-in' type='checkbox'><label for='data-49708d7c-b454-4a83-9d7a-93c7c082f538' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>time</span></div><div class='xr-var-dims'>(year, month)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 ... 1197 1198 1199 1200</div><input id='attrs-54ffb0ae-9256-4fa8-8a20-e1ae559cb07f' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-54ffb0ae-9256-4fa8-8a20-e1ae559cb07f' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-0102c1eb-782a-43b9-aaae-718c2a232e8d' class='xr-var-data-in' type='checkbox'><label for='data-0102c1eb-782a-43b9-aaae-718c2a232e8d' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[   1,    2,    3, ...,   10,   11,   12],\n",
       "       [  13,   14,   15, ...,   22,   23,   24],\n",
       "       [  25,   26,   27, ...,   34,   35,   36],\n",
       "       ...,\n",
       "       [1165, 1166, 1167, ..., 1174, 1175, 1176],\n",
       "       [1177, 1178, 1179, ..., 1186, 1187, 1188],\n",
       "       [1189, 1190, 1191, ..., 1198, 1199, 1200]], dtype=int32)</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-441447f7-b962-47e7-a377-066182ad922c' class='xr-section-summary-in' type='checkbox'  checked><label for='section-441447f7-b962-47e7-a377-066182ad922c' class='xr-section-summary' >Data variables: <span>(5)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span>sst</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-0e77d6b3-fb89-40f2-a119-4e7170d5d4ef' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-0e77d6b3-fb89-40f2-a119-4e7170d5d4ef' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-4b9d318a-2d98-41f0-99b1-aa44b443cc28' class='xr-var-data-in' type='checkbox'><label for='data-4b9d318a-2d98-41f0-99b1-aa44b443cc28' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[2073600 values with dtype=float32]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>t300</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-7dc32efc-4cde-417f-8901-29120b6c9e79' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-7dc32efc-4cde-417f-8901-29120b6c9e79' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-202ef7bc-9089-499a-9e0b-7f9d6360a9c6' class='xr-var-data-in' type='checkbox'><label for='data-202ef7bc-9089-499a-9e0b-7f9d6360a9c6' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[2073600 values with dtype=float32]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>ua</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-4bef31c8-d6a0-487c-9589-daed89936141' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-4bef31c8-d6a0-487c-9589-daed89936141' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-4e4d1562-7584-4efa-9aaf-a2bd74802f07' class='xr-var-data-in' type='checkbox'><label for='data-4e4d1562-7584-4efa-9aaf-a2bd74802f07' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[2073600 values with dtype=float64]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>va</span></div><div class='xr-var-dims'>(year, month, lat, lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>...</div><input id='attrs-9cca0fab-0a68-4643-8296-2f19bdb75113' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-9cca0fab-0a68-4643-8296-2f19bdb75113' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-1a02c660-5235-4202-aa53-5139cb161110' class='xr-var-data-in' type='checkbox'><label for='data-1a02c660-5235-4202-aa53-5139cb161110' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>[2073600 values with dtype=float64]</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>nino</span></div><div class='xr-var-dims'>(year, month)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-0.4072 -0.2024 ... -1.177 -1.365</div><input id='attrs-934c076f-f5a7-4ef3-8386-31a18c3e944c' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-934c076f-f5a7-4ef3-8386-31a18c3e944c' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-dfec63cd-a80b-4c60-bcec-d25130b417d9' class='xr-var-data-in' type='checkbox'><label for='data-dfec63cd-a80b-4c60-bcec-d25130b417d9' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[-0.40720701, -0.20244436, -0.10386104, ...,  0.10612228,\n",
       "         0.21165498,  0.16504486],\n",
       "       [ 0.06697161,  0.00999126, -0.00164753, ..., -0.39393583,\n",
       "        -0.49975768, -0.58400702],\n",
       "       [-0.73201811, -0.72508991, -0.58416802, ...,  0.02755602,\n",
       "         0.011619  , -0.04931002],\n",
       "       ...,\n",
       "       [-0.679456  , -0.79953653, -0.78681421, ...,  0.30063489,\n",
       "         0.43758485,  0.60009205],\n",
       "       [ 0.69772309,  0.58855242,  0.36855501, ...,  0.52580005,\n",
       "         0.45631215,  0.35908446],\n",
       "       [ 0.21041885,  0.01216245, -0.18615368, ..., -0.97617215,\n",
       "        -1.17681098, -1.36528361]])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-4a40331f-b3c9-47f6-bc56-9d548b2db912' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-4a40331f-b3c9-47f6-bc56-9d548b2db912' class='xr-section-summary'  title='Expand/collapse section'>Attributes: <span>(0)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><dl class='xr-attrs'></dl></div></li></ul></div></div>"
      ],
      "text/plain": [
       "<xarray.Dataset>\n",
       "Dimensions:  (lat: 24, lon: 72, mode: 100, month: 12, year: 100)\n",
       "Coordinates:\n",
       "  * year     (year) int32 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int32 1 2 3 4 5 6 7 8 9 10 11 12\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "  * mode     (mode) int64 10000 10000 10000 10000 ... 10000 10000 10000 10000\n",
       "    time     (year, month) int32 1 2 3 4 5 6 7 ... 1195 1196 1197 1198 1199 1200\n",
       "Data variables:\n",
       "    sst      (year, month, lat, lon) float32 ...\n",
       "    t300     (year, month, lat, lon) float32 ...\n",
       "    ua       (year, month, lat, lon) float64 ...\n",
       "    va       (year, month, lat, lon) float64 ...\n",
       "    nino     (year, month) float64 -0.4072 -0.2024 -0.1039 ... -1.177 -1.365"
      ]
     },
     "execution_count": 388,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "SODA['time']=SODA.year*12+SODA.month-12\n",
    "SODA=SODA.set_coords('time')\n",
    "SODA"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 401,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div><svg style=\"position: absolute; width: 0; height: 0; overflow: hidden\">\n",
       "<defs>\n",
       "<symbol id=\"icon-database\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M16 0c-8.837 0-16 2.239-16 5v4c0 2.761 7.163 5 16 5s16-2.239 16-5v-4c0-2.761-7.163-5-16-5z\"></path>\n",
       "<path d=\"M16 17c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "<path d=\"M16 26c-8.837 0-16-2.239-16-5v6c0 2.761 7.163 5 16 5s16-2.239 16-5v-6c0 2.761-7.163 5-16 5z\"></path>\n",
       "</symbol>\n",
       "<symbol id=\"icon-file-text2\" viewBox=\"0 0 32 32\">\n",
       "<path d=\"M28.681 7.159c-0.694-0.947-1.662-2.053-2.724-3.116s-2.169-2.030-3.116-2.724c-1.612-1.182-2.393-1.319-2.841-1.319h-15.5c-1.378 0-2.5 1.121-2.5 2.5v27c0 1.378 1.122 2.5 2.5 2.5h23c1.378 0 2.5-1.122 2.5-2.5v-19.5c0-0.448-0.137-1.23-1.319-2.841zM24.543 5.457c0.959 0.959 1.712 1.825 2.268 2.543h-4.811v-4.811c0.718 0.556 1.584 1.309 2.543 2.268zM28 29.5c0 0.271-0.229 0.5-0.5 0.5h-23c-0.271 0-0.5-0.229-0.5-0.5v-27c0-0.271 0.229-0.5 0.5-0.5 0 0 15.499-0 15.5 0v7c0 0.552 0.448 1 1 1h7v19.5z\"></path>\n",
       "<path d=\"M23 26h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 22h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "<path d=\"M23 18h-14c-0.552 0-1-0.448-1-1s0.448-1 1-1h14c0.552 0 1 0.448 1 1s-0.448 1-1 1z\"></path>\n",
       "</symbol>\n",
       "</defs>\n",
       "</svg>\n",
       "<style>/* CSS stylesheet for displaying xarray objects in jupyterlab.\n",
       " *\n",
       " */\n",
       "\n",
       ":root {\n",
       "  --xr-font-color0: var(--jp-content-font-color0, rgba(0, 0, 0, 1));\n",
       "  --xr-font-color2: var(--jp-content-font-color2, rgba(0, 0, 0, 0.54));\n",
       "  --xr-font-color3: var(--jp-content-font-color3, rgba(0, 0, 0, 0.38));\n",
       "  --xr-border-color: var(--jp-border-color2, #e0e0e0);\n",
       "  --xr-disabled-color: var(--jp-layout-color3, #bdbdbd);\n",
       "  --xr-background-color: var(--jp-layout-color0, white);\n",
       "  --xr-background-color-row-even: var(--jp-layout-color1, white);\n",
       "  --xr-background-color-row-odd: var(--jp-layout-color2, #eeeeee);\n",
       "}\n",
       "\n",
       "html[theme=dark],\n",
       "body.vscode-dark {\n",
       "  --xr-font-color0: rgba(255, 255, 255, 1);\n",
       "  --xr-font-color2: rgba(255, 255, 255, 0.54);\n",
       "  --xr-font-color3: rgba(255, 255, 255, 0.38);\n",
       "  --xr-border-color: #1F1F1F;\n",
       "  --xr-disabled-color: #515151;\n",
       "  --xr-background-color: #111111;\n",
       "  --xr-background-color-row-even: #111111;\n",
       "  --xr-background-color-row-odd: #313131;\n",
       "}\n",
       "\n",
       ".xr-wrap {\n",
       "  display: block;\n",
       "  min-width: 300px;\n",
       "  max-width: 700px;\n",
       "}\n",
       "\n",
       ".xr-text-repr-fallback {\n",
       "  /* fallback to plain text repr when CSS is not injected (untrusted notebook) */\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-header {\n",
       "  padding-top: 6px;\n",
       "  padding-bottom: 6px;\n",
       "  margin-bottom: 4px;\n",
       "  border-bottom: solid 1px var(--xr-border-color);\n",
       "}\n",
       "\n",
       ".xr-header > div,\n",
       ".xr-header > ul {\n",
       "  display: inline;\n",
       "  margin-top: 0;\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-obj-type,\n",
       ".xr-array-name {\n",
       "  margin-left: 2px;\n",
       "  margin-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-obj-type {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-sections {\n",
       "  padding-left: 0 !important;\n",
       "  display: grid;\n",
       "  grid-template-columns: 150px auto auto 1fr 20px 20px;\n",
       "}\n",
       "\n",
       ".xr-section-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-section-item input {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-item input + label {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label {\n",
       "  cursor: pointer;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-item input:enabled + label:hover {\n",
       "  color: var(--xr-font-color0);\n",
       "}\n",
       "\n",
       ".xr-section-summary {\n",
       "  grid-column: 1;\n",
       "  color: var(--xr-font-color2);\n",
       "  font-weight: 500;\n",
       "}\n",
       "\n",
       ".xr-section-summary > span {\n",
       "  display: inline-block;\n",
       "  padding-left: 0.5em;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label {\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in + label:before {\n",
       "  display: inline-block;\n",
       "  content: '►';\n",
       "  font-size: 11px;\n",
       "  width: 15px;\n",
       "  text-align: center;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:disabled + label:before {\n",
       "  color: var(--xr-disabled-color);\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label:before {\n",
       "  content: '▼';\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked + label > span {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-section-summary,\n",
       ".xr-section-inline-details {\n",
       "  padding-top: 4px;\n",
       "  padding-bottom: 4px;\n",
       "}\n",
       "\n",
       ".xr-section-inline-details {\n",
       "  grid-column: 2 / -1;\n",
       "}\n",
       "\n",
       ".xr-section-details {\n",
       "  display: none;\n",
       "  grid-column: 1 / -1;\n",
       "  margin-bottom: 5px;\n",
       "}\n",
       "\n",
       ".xr-section-summary-in:checked ~ .xr-section-details {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-array-wrap {\n",
       "  grid-column: 1 / -1;\n",
       "  display: grid;\n",
       "  grid-template-columns: 20px auto;\n",
       "}\n",
       "\n",
       ".xr-array-wrap > label {\n",
       "  grid-column: 1;\n",
       "  vertical-align: top;\n",
       "}\n",
       "\n",
       ".xr-preview {\n",
       "  color: var(--xr-font-color3);\n",
       "}\n",
       "\n",
       ".xr-array-preview,\n",
       ".xr-array-data {\n",
       "  padding: 0 5px !important;\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-array-data,\n",
       ".xr-array-in:checked ~ .xr-array-preview {\n",
       "  display: none;\n",
       "}\n",
       "\n",
       ".xr-array-in:checked ~ .xr-array-data,\n",
       ".xr-array-preview {\n",
       "  display: inline-block;\n",
       "}\n",
       "\n",
       ".xr-dim-list {\n",
       "  display: inline-block !important;\n",
       "  list-style: none;\n",
       "  padding: 0 !important;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list li {\n",
       "  display: inline-block;\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "}\n",
       "\n",
       ".xr-dim-list:before {\n",
       "  content: '(';\n",
       "}\n",
       "\n",
       ".xr-dim-list:after {\n",
       "  content: ')';\n",
       "}\n",
       "\n",
       ".xr-dim-list li:not(:last-child):after {\n",
       "  content: ',';\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-has-index {\n",
       "  font-weight: bold;\n",
       "}\n",
       "\n",
       ".xr-var-list,\n",
       ".xr-var-item {\n",
       "  display: contents;\n",
       "}\n",
       "\n",
       ".xr-var-item > div,\n",
       ".xr-var-item label,\n",
       ".xr-var-item > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-even);\n",
       "  margin-bottom: 0;\n",
       "}\n",
       "\n",
       ".xr-var-item > .xr-var-name:hover span {\n",
       "  padding-right: 5px;\n",
       "}\n",
       "\n",
       ".xr-var-list > li:nth-child(odd) > div,\n",
       ".xr-var-list > li:nth-child(odd) > label,\n",
       ".xr-var-list > li:nth-child(odd) > .xr-var-name span {\n",
       "  background-color: var(--xr-background-color-row-odd);\n",
       "}\n",
       "\n",
       ".xr-var-name {\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-var-dims {\n",
       "  grid-column: 2;\n",
       "}\n",
       "\n",
       ".xr-var-dtype {\n",
       "  grid-column: 3;\n",
       "  text-align: right;\n",
       "  color: var(--xr-font-color2);\n",
       "}\n",
       "\n",
       ".xr-var-preview {\n",
       "  grid-column: 4;\n",
       "}\n",
       "\n",
       ".xr-var-name,\n",
       ".xr-var-dims,\n",
       ".xr-var-dtype,\n",
       ".xr-preview,\n",
       ".xr-attrs dt {\n",
       "  white-space: nowrap;\n",
       "  overflow: hidden;\n",
       "  text-overflow: ellipsis;\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-var-name:hover,\n",
       ".xr-var-dims:hover,\n",
       ".xr-var-dtype:hover,\n",
       ".xr-attrs dt:hover {\n",
       "  overflow: visible;\n",
       "  width: auto;\n",
       "  z-index: 1;\n",
       "}\n",
       "\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  display: none;\n",
       "  background-color: var(--xr-background-color) !important;\n",
       "  padding-bottom: 5px !important;\n",
       "}\n",
       "\n",
       ".xr-var-attrs-in:checked ~ .xr-var-attrs,\n",
       ".xr-var-data-in:checked ~ .xr-var-data {\n",
       "  display: block;\n",
       "}\n",
       "\n",
       ".xr-var-data > table {\n",
       "  float: right;\n",
       "}\n",
       "\n",
       ".xr-var-name span,\n",
       ".xr-var-data,\n",
       ".xr-attrs {\n",
       "  padding-left: 25px !important;\n",
       "}\n",
       "\n",
       ".xr-attrs,\n",
       ".xr-var-attrs,\n",
       ".xr-var-data {\n",
       "  grid-column: 1 / -1;\n",
       "}\n",
       "\n",
       "dl.xr-attrs {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  display: grid;\n",
       "  grid-template-columns: 125px auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt, dd {\n",
       "  padding: 0;\n",
       "  margin: 0;\n",
       "  float: left;\n",
       "  padding-right: 10px;\n",
       "  width: auto;\n",
       "}\n",
       "\n",
       ".xr-attrs dt {\n",
       "  font-weight: normal;\n",
       "  grid-column: 1;\n",
       "}\n",
       "\n",
       ".xr-attrs dt:hover span {\n",
       "  display: inline-block;\n",
       "  background: var(--xr-background-color);\n",
       "  padding-right: 10px;\n",
       "}\n",
       "\n",
       ".xr-attrs dd {\n",
       "  grid-column: 2;\n",
       "  white-space: pre-wrap;\n",
       "  word-break: break-all;\n",
       "}\n",
       "\n",
       ".xr-icon-database,\n",
       ".xr-icon-file-text2 {\n",
       "  display: inline-block;\n",
       "  vertical-align: middle;\n",
       "  width: 1em;\n",
       "  height: 1.5em !important;\n",
       "  stroke-width: 0;\n",
       "  stroke: currentColor;\n",
       "  fill: currentColor;\n",
       "}\n",
       "</style><pre class='xr-text-repr-fallback'>&lt;xarray.Dataset&gt;\n",
       "Dimensions:  (lat: 24, lon: 72, mode: 100, month: 12, year: 100)\n",
       "Coordinates:\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "  * mode     (mode) int64 10000 10000 10000 10000 ... 10000 10000 10000 10000\n",
       "    time     (year, month) int32 1 2 3 4 5 6 7 ... 1195 1196 1197 1198 1199 1200\n",
       "  * year     (year) int64 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int64 1 2 3 4 5 6 7 8 9 10 11 12\n",
       "Data variables:\n",
       "    sst      (lat, lon, year, month) float32 1.8618509 1.2667823 ... -0.01160882\n",
       "    t300     (lat, lon, year, month) float32 0.3742796 0.32198605 ... 0.02676518\n",
       "    ua       (lat, lon, year, month) float64 0.4293 1.043 ... -2.384 1.878\n",
       "    va       (lat, lon, year, month) float64 0.08719 0.1337 ... -1.478 -2.785\n",
       "    nino     (year, month) float64 -0.4072 -0.2024 -0.1039 ... -1.177 -1.365</pre><div class='xr-wrap' hidden><div class='xr-header'><div class='xr-obj-type'>xarray.Dataset</div></div><ul class='xr-sections'><li class='xr-section-item'><input id='section-aabdf8f2-4172-4345-9307-6bc57887925b' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-aabdf8f2-4172-4345-9307-6bc57887925b' class='xr-section-summary'  title='Expand/collapse section'>Dimensions:</label><div class='xr-section-inline-details'><ul class='xr-dim-list'><li><span class='xr-has-index'>lat</span>: 24</li><li><span class='xr-has-index'>lon</span>: 72</li><li><span class='xr-has-index'>mode</span>: 100</li><li><span class='xr-has-index'>month</span>: 12</li><li><span class='xr-has-index'>year</span>: 100</li></ul></div><div class='xr-section-details'></div></li><li class='xr-section-item'><input id='section-f254b5bd-28ff-4100-a9a2-883ef2043240' class='xr-section-summary-in' type='checkbox'  checked><label for='section-f254b5bd-28ff-4100-a9a2-883ef2043240' class='xr-section-summary' >Coordinates: <span>(6)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lat</span></div><div class='xr-var-dims'>(lat)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-55.0 -50.0 -45.0 ... 55.0 60.0</div><input id='attrs-53ab2268-b93f-4f25-b7d6-c008c68d50fd' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-53ab2268-b93f-4f25-b7d6-c008c68d50fd' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-1b2b1c2a-5eb4-42a9-8b21-9c21522d1ea8' class='xr-var-data-in' type='checkbox'><label for='data-1b2b1c2a-5eb4-42a9-8b21-9c21522d1ea8' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([-55., -50., -45., -40., -35., -30., -25., -20., -15., -10.,  -5.,   0.,\n",
       "         5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,  60.])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>lon</span></div><div class='xr-var-dims'>(lon)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.0 5.0 10.0 ... 345.0 350.0 355.0</div><input id='attrs-a9259529-0f1f-492d-b170-61258c447873' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-a9259529-0f1f-492d-b170-61258c447873' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-5b4de98a-012f-41b5-8e4f-4be4d67b0a9e' class='xr-var-data-in' type='checkbox'><label for='data-5b4de98a-012f-41b5-8e4f-4be4d67b0a9e' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  0.,   5.,  10.,  15.,  20.,  25.,  30.,  35.,  40.,  45.,  50.,  55.,\n",
       "        60.,  65.,  70.,  75.,  80.,  85.,  90.,  95., 100., 105., 110., 115.,\n",
       "       120., 125., 130., 135., 140., 145., 150., 155., 160., 165., 170., 175.,\n",
       "       180., 185., 190., 195., 200., 205., 210., 215., 220., 225., 230., 235.,\n",
       "       240., 245., 250., 255., 260., 265., 270., 275., 280., 285., 290., 295.,\n",
       "       300., 305., 310., 315., 320., 325., 330., 335., 340., 345., 350., 355.])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>mode</span></div><div class='xr-var-dims'>(mode)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>10000 10000 10000 ... 10000 10000</div><input id='attrs-926d1d12-3ba9-48d2-a253-bc70cb3f9302' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-926d1d12-3ba9-48d2-a253-bc70cb3f9302' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-8ea7f375-9f1f-4ae3-97e0-418e915a72f6' class='xr-var-data-in' type='checkbox'><label for='data-8ea7f375-9f1f-4ae3-97e0-418e915a72f6' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000,\n",
       "       10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000, 10000])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>time</span></div><div class='xr-var-dims'>(year, month)</div><div class='xr-var-dtype'>int32</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 ... 1197 1198 1199 1200</div><input id='attrs-bd50d85b-8a29-4fb1-85c2-0c7a942a9980' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-bd50d85b-8a29-4fb1-85c2-0c7a942a9980' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-ec9440f7-be03-4a4c-bf4a-64e0635f05f7' class='xr-var-data-in' type='checkbox'><label for='data-ec9440f7-be03-4a4c-bf4a-64e0635f05f7' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[   1,    2,    3, ...,   10,   11,   12],\n",
       "       [  13,   14,   15, ...,   22,   23,   24],\n",
       "       [  25,   26,   27, ...,   34,   35,   36],\n",
       "       ...,\n",
       "       [1165, 1166, 1167, ..., 1174, 1175, 1176],\n",
       "       [1177, 1178, 1179, ..., 1186, 1187, 1188],\n",
       "       [1189, 1190, 1191, ..., 1198, 1199, 1200]], dtype=int32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>year</span></div><div class='xr-var-dims'>(year)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 ... 95 96 97 98 99 100</div><input id='attrs-1b1a7271-8656-4588-83c1-1cfed312febc' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-1b1a7271-8656-4588-83c1-1cfed312febc' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-4da05fd6-cfaa-4cf1-95e4-3fdd14b7a297' class='xr-var-data-in' type='checkbox'><label for='data-4da05fd6-cfaa-4cf1-95e4-3fdd14b7a297' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([  1,   2,   3,   4,   5,   6,   7,   8,   9,  10,  11,  12,  13,  14,\n",
       "        15,  16,  17,  18,  19,  20,  21,  22,  23,  24,  25,  26,  27,  28,\n",
       "        29,  30,  31,  32,  33,  34,  35,  36,  37,  38,  39,  40,  41,  42,\n",
       "        43,  44,  45,  46,  47,  48,  49,  50,  51,  52,  53,  54,  55,  56,\n",
       "        57,  58,  59,  60,  61,  62,  63,  64,  65,  66,  67,  68,  69,  70,\n",
       "        71,  72,  73,  74,  75,  76,  77,  78,  79,  80,  81,  82,  83,  84,\n",
       "        85,  86,  87,  88,  89,  90,  91,  92,  93,  94,  95,  96,  97,  98,\n",
       "        99, 100])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span class='xr-has-index'>month</span></div><div class='xr-var-dims'>(month)</div><div class='xr-var-dtype'>int64</div><div class='xr-var-preview xr-preview'>1 2 3 4 5 6 7 8 9 10 11 12</div><input id='attrs-4d62634c-8325-4a9f-9bae-0b0ef18f130a' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-4d62634c-8325-4a9f-9bae-0b0ef18f130a' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-e24db392-eb3b-4671-a1eb-1092c472cb64' class='xr-var-data-in' type='checkbox'><label for='data-e24db392-eb3b-4671-a1eb-1092c472cb64' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([ 1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-7b627fbc-5be1-49d2-86b6-e86f2e1f7cb7' class='xr-section-summary-in' type='checkbox'  checked><label for='section-7b627fbc-5be1-49d2-86b6-e86f2e1f7cb7' class='xr-section-summary' >Data variables: <span>(5)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><ul class='xr-var-list'><li class='xr-var-item'><div class='xr-var-name'><span>sst</span></div><div class='xr-var-dims'>(lat, lon, year, month)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>1.8618509 1.2667823 ... -0.01160882</div><input id='attrs-9aab9913-74f6-4f75-b33b-bec69a5fc9be' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-9aab9913-74f6-4f75-b33b-bec69a5fc9be' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-349b86b6-3357-41bc-b5ed-643c3935aeec' class='xr-var-data-in' type='checkbox'><label for='data-349b86b6-3357-41bc-b5ed-643c3935aeec' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[ 1.86185086e+00,  1.26678228e+00,  8.16348493e-01, ...,\n",
       "          -5.59044294e-02, -7.94515908e-02, -2.80100405e-01],\n",
       "         [-2.72263676e-01,  1.24272145e-01,  3.37311894e-01, ...,\n",
       "          -1.97112523e-02, -1.69727787e-01, -1.36654541e-01],\n",
       "         [ 2.91070752e-02,  4.56265628e-01,  4.26018506e-01, ...,\n",
       "          -5.06161340e-02, -2.79493630e-01, -2.45314136e-01],\n",
       "         ...,\n",
       "         [-1.20114577e+00, -1.20931709e+00, -7.88750589e-01, ...,\n",
       "           1.42514855e-01, -3.87997851e-02,  4.54133861e-02],\n",
       "         [ 1.52546063e-01, -3.82228345e-02, -5.51603660e-02, ...,\n",
       "           6.47056252e-02, -4.04604167e-01, -4.84885305e-01],\n",
       "         [-4.80489433e-01, -7.39594996e-01, -2.13334769e-01, ...,\n",
       "           1.70891479e-01, -1.40965581e-01, -7.17795432e-01]],\n",
       "\n",
       "        [[ 2.69307733e+00,  1.90728414e+00,  1.16463184e+00, ...,\n",
       "           2.73450669e-02,  1.01248674e-01,  1.09355683e-02],\n",
       "         [-1.32154033e-01,  1.86474085e-01,  4.64030415e-01, ...,\n",
       "           1.52265432e-03, -8.42903703e-02, -3.24831866e-02],\n",
       "         [ 6.06700294e-02,  5.89571297e-01,  4.80494678e-01, ...,\n",
       "          -8.78236294e-02, -3.00841898e-01, -1.98555529e-01],\n",
       "...\n",
       "           8.83855581e-01,  6.29130840e-01,  4.16080058e-01],\n",
       "         [ 1.35166734e-01,  6.19132631e-02,  3.04309815e-01, ...,\n",
       "          -2.56816506e-01, -4.52134430e-01, -2.67999142e-01],\n",
       "         [ 2.14841872e-01,  1.81274459e-01, -3.32805924e-02, ...,\n",
       "          -1.42347217e-01, -1.83111757e-01, -3.91992629e-02]],\n",
       "\n",
       "        [[-1.39975393e+00, -8.20150614e-01, -1.02529116e-01, ...,\n",
       "           7.05155194e-01,  9.60352898e-01,  5.40099084e-01],\n",
       "         [ 2.95828462e-01,  1.94928452e-01,  2.54364848e-01, ...,\n",
       "          -5.91010153e-01, -6.59970284e-01, -8.65866780e-01],\n",
       "         [ 7.64520094e-02, -2.21396551e-01, -3.06507647e-01, ...,\n",
       "          -1.53019011e-01,  8.04345012e-02,  5.44332325e-01],\n",
       "         ...,\n",
       "         [-3.28857422e-01, -3.40106130e-01, -3.51297051e-01, ...,\n",
       "           8.98509622e-01,  5.16191483e-01,  3.43746543e-01],\n",
       "         [-2.22143352e-01, -3.13660532e-01, -6.82313621e-01, ...,\n",
       "           2.14824118e-02, -1.15113668e-01, -2.60012358e-01],\n",
       "         [-8.34703073e-03,  1.47475764e-01, -1.96601018e-01, ...,\n",
       "           2.61782319e-03,  2.27584150e-02, -1.16088204e-02]]]],\n",
       "      dtype=float32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>t300</span></div><div class='xr-var-dims'>(lat, lon, year, month)</div><div class='xr-var-dtype'>float32</div><div class='xr-var-preview xr-preview'>0.3742796 0.32198605 ... 0.02676518</div><input id='attrs-9e9c00e5-412c-4b7f-bb9d-a5d7b4b69a68' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-9e9c00e5-412c-4b7f-bb9d-a5d7b4b69a68' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-8ecb58f5-7e43-4f0b-b4d4-4f96b2a6381c' class='xr-var-data-in' type='checkbox'><label for='data-8ecb58f5-7e43-4f0b-b4d4-4f96b2a6381c' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[ 3.74279588e-01,  3.21986049e-01,  2.69083917e-01, ...,\n",
       "           1.05930030e-01,  9.78918001e-02,  7.40093514e-02],\n",
       "         [ 6.20391332e-02,  4.96488251e-02,  4.24894616e-02, ...,\n",
       "           6.04596436e-02,  4.00456153e-02,  3.35965082e-02],\n",
       "         [ 2.36240607e-02,  1.04728965e-02, -2.17825198e-03, ...,\n",
       "          -1.01246638e-02, -1.81315690e-02, -9.50849056e-03],\n",
       "         ...,\n",
       "         [-1.13733374e-01, -2.55540669e-01, -3.95079523e-01, ...,\n",
       "          -3.53544466e-02, -1.01305023e-02,  2.99106073e-02],\n",
       "         [ 8.29594508e-02,  2.24544734e-01,  1.91576988e-01, ...,\n",
       "           1.31118685e-01,  1.19014703e-01,  1.52714580e-01],\n",
       "         [ 1.87718749e-01,  1.57902315e-01,  1.58516660e-01, ...,\n",
       "           1.15932204e-01,  9.04440284e-02,  6.10991530e-02]],\n",
       "\n",
       "        [[ 3.31764013e-01,  2.67700136e-01,  2.10542694e-01, ...,\n",
       "           1.08705327e-01,  1.18184336e-01,  1.17402233e-01],\n",
       "         [ 1.00242861e-01,  9.78059918e-02,  7.88039267e-02, ...,\n",
       "           3.15207653e-02,  2.58261058e-02,  3.88837606e-02],\n",
       "         [ 3.69017832e-02,  3.92119139e-02,  1.98624562e-02, ...,\n",
       "          -3.61533798e-02, -3.22513245e-02, -1.30044222e-02],\n",
       "...\n",
       "           3.77458245e-01,  3.11322302e-01,  1.89998254e-01],\n",
       "         [ 1.02721259e-01,  7.98833072e-02,  2.96467900e-01, ...,\n",
       "           4.18162256e-01,  2.08741635e-01,  1.60261691e-01],\n",
       "         [ 3.01508367e-01,  2.05194384e-01,  6.97829947e-03, ...,\n",
       "           1.30289003e-01,  1.70507357e-01,  2.23673686e-01]],\n",
       "\n",
       "        [[-9.49816167e-01, -7.48450756e-01, -1.77347705e-01, ...,\n",
       "          -4.57154065e-01,  2.44643465e-01,  3.40770572e-01],\n",
       "         [ 3.70073438e-01,  3.54315102e-01,  4.20774251e-01, ...,\n",
       "          -5.85433245e-01, -4.51328248e-01, -4.08036262e-01],\n",
       "         [ 2.25731745e-01, -1.36658877e-01, -2.00330243e-01, ...,\n",
       "          -1.19508557e-01,  1.06314845e-01,  5.06483674e-01],\n",
       "         ...,\n",
       "         [-3.02483082e-01, -3.22150916e-01, -3.51976663e-01, ...,\n",
       "           5.78525305e-01,  4.55707401e-01,  3.82585734e-01],\n",
       "         [-1.91341832e-01, -2.64561951e-01, -5.86121559e-01, ...,\n",
       "           3.64489287e-01,  2.17719853e-01, -1.28290117e-01],\n",
       "         [ 1.35609310e-03,  1.68556750e-01, -1.40020818e-01, ...,\n",
       "           1.17978752e-01, -4.12444538e-03,  2.67651808e-02]]]],\n",
       "      dtype=float32)</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>ua</span></div><div class='xr-var-dims'>(lat, lon, year, month)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.4293 1.043 ... -2.384 1.878</div><input id='attrs-b0bfe156-dd9c-4362-844e-e7f6c52e951d' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-b0bfe156-dd9c-4362-844e-e7f6c52e951d' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-c362098f-1ffd-414a-95ac-92e149becb40' class='xr-var-data-in' type='checkbox'><label for='data-c362098f-1ffd-414a-95ac-92e149becb40' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[ 4.29292202e-01,  1.04252148e+00,  5.63025475e-02, ...,\n",
       "          -1.10989285e+00, -2.52302170e-01,  9.16201353e-01],\n",
       "         [ 2.03301811e+00,  6.34977818e-01,  3.19267273e-01, ...,\n",
       "          -1.53573036e-01,  4.74976063e-01,  2.06240892e-01],\n",
       "         [ 1.47628784e-02,  2.32324600e-01,  3.77445221e-02, ...,\n",
       "          -2.40518093e-01,  1.49109364e-01,  8.58562231e-01],\n",
       "         ...,\n",
       "         [ 1.23233223e+00, -9.90877151e-01, -2.92215347e-02, ...,\n",
       "          -8.89539480e-01,  2.45907784e-01, -6.86558247e-01],\n",
       "         [-3.58821249e+00, -6.29327774e-01,  1.61753559e+00, ...,\n",
       "           5.66732883e-01,  2.69630623e+00,  1.45081544e+00],\n",
       "         [ 2.46083260e-01,  5.07016182e-02,  2.68875599e-01, ...,\n",
       "          -1.35818958e-01,  2.23667145e+00, -3.44751120e-01]],\n",
       "\n",
       "        [[ 3.21262836e-01,  9.48317051e-01,  5.02028465e-02, ...,\n",
       "          -1.20874238e+00, -3.19251060e-01,  9.59947586e-01],\n",
       "         [ 1.98910189e+00,  6.45006657e-01,  3.06715965e-01, ...,\n",
       "          -2.61696815e-01,  4.04694080e-01,  1.61680222e-01],\n",
       "         [ 1.52701855e-01,  2.54637718e-01,  2.20966339e-03, ...,\n",
       "          -3.34931850e-01,  1.26327515e-01,  7.79727936e-01],\n",
       "...\n",
       "         [ 2.44442892e+00, -2.10571146e+00,  5.55653572e+00, ...,\n",
       "          -4.07228756e+00, -4.30891609e+00, -3.25312996e+00],\n",
       "         [-4.27208376e+00, -1.67652059e+00, -1.81606293e+00, ...,\n",
       "           3.19648504e+00,  2.02273226e+00,  5.54002047e-01],\n",
       "         [-5.44746494e+00, -5.76848269e-01,  3.70342278e+00, ...,\n",
       "           2.47215891e+00, -2.29148602e+00,  1.87980628e+00]],\n",
       "\n",
       "        [[ 1.21132612e-01,  2.25900650e-01,  2.73725605e+00, ...,\n",
       "          -9.67601418e-01, -1.40583158e+00,  3.03591609e+00],\n",
       "         [-7.16270208e-01, -4.94462013e+00, -1.21631169e+00, ...,\n",
       "          -4.45555568e-01, -1.64230335e+00, -5.80912542e+00],\n",
       "         [ 3.14668179e-01,  1.24338222e+00, -1.17646313e+00, ...,\n",
       "           1.03483796e+00, -9.48170006e-01,  4.94480896e+00],\n",
       "         ...,\n",
       "         [ 2.82457614e+00, -1.44461346e+00,  4.49366760e+00, ...,\n",
       "          -2.87910271e+00, -3.86720467e+00, -2.44426298e+00],\n",
       "         [-4.28346872e+00, -2.72228837e+00, -2.10110807e+00, ...,\n",
       "           2.99733090e+00,  2.15736055e+00, -6.68582797e-01],\n",
       "         [-5.87256002e+00, -6.96276665e-01,  3.28813553e+00, ...,\n",
       "           2.49356961e+00, -2.38394117e+00,  1.87778592e+00]]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>va</span></div><div class='xr-var-dims'>(lat, lon, year, month)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>0.08719 0.1337 ... -1.478 -2.785</div><input id='attrs-45ca4472-8d71-45b8-8218-2813526f5f4e' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-45ca4472-8d71-45b8-8218-2813526f5f4e' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-61b62295-83a4-41a1-88ee-d7e6fb83cb6c' class='xr-var-data-in' type='checkbox'><label for='data-61b62295-83a4-41a1-88ee-d7e6fb83cb6c' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[[[ 8.71891379e-02,  1.33735359e-01, -2.10757673e-01, ...,\n",
       "           9.23671722e-01,  2.79493153e-01, -3.68778884e-01],\n",
       "         [-9.78357315e-01, -2.38034010e-01, -5.39501727e-01, ...,\n",
       "          -8.06723833e-02, -8.46999288e-01, -9.08317566e-02],\n",
       "         [-3.37002784e-01, -1.35312498e-01, -2.48495162e-01, ...,\n",
       "          -1.79814219e-01, -6.08893037e-01, -9.23010468e-01],\n",
       "         ...,\n",
       "         [-1.19876397e+00,  1.43381464e+00, -8.40114176e-01, ...,\n",
       "           1.36031783e+00, -7.84425855e-01,  1.51229590e-01],\n",
       "         [ 1.37889826e+00, -5.88558078e-01, -1.90600657e+00, ...,\n",
       "          -1.98533201e+00, -5.29313087e-01,  4.84679073e-01],\n",
       "         [ 1.65372267e-01, -6.68603778e-02, -5.38478076e-01, ...,\n",
       "           2.84816384e-01,  6.98362529e-01, -3.51496756e-01]],\n",
       "\n",
       "        [[ 6.91163540e-03, -1.59800410e-01, -1.66637897e-02, ...,\n",
       "           7.33455896e-01,  2.83745587e-01, -5.96210122e-01],\n",
       "         [-8.01376760e-01, -3.95147443e-01, -4.87343311e-01, ...,\n",
       "          -9.50818062e-02, -7.88996816e-01, -8.84242654e-02],\n",
       "         [-6.86231911e-01, -3.41794729e-01, -2.64078617e-01, ...,\n",
       "          -2.78094530e-01, -7.45473981e-01, -1.10568368e+00],\n",
       "...\n",
       "         [-1.73551297e+00, -1.67756200e+00, -2.38457739e-01, ...,\n",
       "           2.76644588e-01,  5.12785339e+00, -1.57101107e+00],\n",
       "         [-2.38123775e+00, -3.81397414e+00,  1.21419835e+00, ...,\n",
       "           3.36930132e+00, -5.59453392e+00,  8.18486691e-01],\n",
       "         [ 1.33749413e+00, -4.07218695e+00, -6.18843460e+00, ...,\n",
       "          -1.55934072e+00, -2.02685809e+00, -1.03422129e+00]],\n",
       "\n",
       "        [[ 3.03703523e+00,  1.77813983e+00,  1.74530649e+00, ...,\n",
       "           1.01226687e+00, -4.33359909e+00, -1.56330228e-01],\n",
       "         [ 2.12108541e+00,  2.92923069e+00, -9.19324696e-01, ...,\n",
       "          -6.81996644e-01, -6.77174985e-01, -7.38463759e-01],\n",
       "         [ 2.14348817e+00, -2.60206890e+00,  1.81885934e+00, ...,\n",
       "          -1.27549326e+00, -3.04073524e+00,  7.19276905e-01],\n",
       "         ...,\n",
       "         [-3.13399863e+00, -2.36185169e+00, -4.49372500e-01, ...,\n",
       "           6.21896744e-01,  3.48498178e+00, -1.76293468e+00],\n",
       "         [-7.49481678e-01, -3.25754642e+00,  1.14562225e+00, ...,\n",
       "           2.69036007e+00, -5.35657215e+00,  1.57575679e+00],\n",
       "         [ 1.73255706e+00, -3.50325966e+00, -5.74733305e+00, ...,\n",
       "          -1.53183043e+00, -1.47847986e+00, -2.78541899e+00]]]])</pre></div></li><li class='xr-var-item'><div class='xr-var-name'><span>nino</span></div><div class='xr-var-dims'>(year, month)</div><div class='xr-var-dtype'>float64</div><div class='xr-var-preview xr-preview'>-0.4072 -0.2024 ... -1.177 -1.365</div><input id='attrs-b49e77b8-6862-4158-a3c5-7e9ff50dee67' class='xr-var-attrs-in' type='checkbox' disabled><label for='attrs-b49e77b8-6862-4158-a3c5-7e9ff50dee67' title='Show/Hide attributes'><svg class='icon xr-icon-file-text2'><use xlink:href='#icon-file-text2'></use></svg></label><input id='data-baa01cb2-6fec-4c24-a68d-bcc3fd5310ad' class='xr-var-data-in' type='checkbox'><label for='data-baa01cb2-6fec-4c24-a68d-bcc3fd5310ad' title='Show/Hide data repr'><svg class='icon xr-icon-database'><use xlink:href='#icon-database'></use></svg></label><div class='xr-var-attrs'><dl class='xr-attrs'></dl></div><div class='xr-var-data'><pre>array([[-0.40720701, -0.20244436, -0.10386104, ...,  0.10612228,\n",
       "         0.21165498,  0.16504486],\n",
       "       [ 0.06697161,  0.00999126, -0.00164753, ..., -0.39393583,\n",
       "        -0.49975768, -0.58400702],\n",
       "       [-0.73201811, -0.72508991, -0.58416802, ...,  0.02755602,\n",
       "         0.011619  , -0.04931002],\n",
       "       ...,\n",
       "       [-0.679456  , -0.79953653, -0.78681421, ...,  0.30063489,\n",
       "         0.43758485,  0.60009205],\n",
       "       [ 0.69772309,  0.58855242,  0.36855501, ...,  0.52580005,\n",
       "         0.45631215,  0.35908446],\n",
       "       [ 0.21041885,  0.01216245, -0.18615368, ..., -0.97617215,\n",
       "        -1.17681098, -1.36528361]])</pre></div></li></ul></div></li><li class='xr-section-item'><input id='section-1c8bb28c-8556-4783-95e4-2b6ee71ee592' class='xr-section-summary-in' type='checkbox' disabled ><label for='section-1c8bb28c-8556-4783-95e4-2b6ee71ee592' class='xr-section-summary'  title='Expand/collapse section'>Attributes: <span>(0)</span></label><div class='xr-section-inline-details'></div><div class='xr-section-details'><dl class='xr-attrs'></dl></div></li></ul></div></div>"
      ],
      "text/plain": [
       "<xarray.Dataset>\n",
       "Dimensions:  (lat: 24, lon: 72, mode: 100, month: 12, year: 100)\n",
       "Coordinates:\n",
       "  * lat      (lat) float64 -55.0 -50.0 -45.0 -40.0 -35.0 ... 45.0 50.0 55.0 60.0\n",
       "  * lon      (lon) float64 0.0 5.0 10.0 15.0 20.0 ... 340.0 345.0 350.0 355.0\n",
       "  * mode     (mode) int64 10000 10000 10000 10000 ... 10000 10000 10000 10000\n",
       "    time     (year, month) int32 1 2 3 4 5 6 7 ... 1195 1196 1197 1198 1199 1200\n",
       "  * year     (year) int64 1 2 3 4 5 6 7 8 9 10 ... 92 93 94 95 96 97 98 99 100\n",
       "  * month    (month) int64 1 2 3 4 5 6 7 8 9 10 11 12\n",
       "Data variables:\n",
       "    sst      (lat, lon, year, month) float32 1.8618509 1.2667823 ... -0.01160882\n",
       "    t300     (lat, lon, year, month) float32 0.3742796 0.32198605 ... 0.02676518\n",
       "    ua       (lat, lon, year, month) float64 0.4293 1.043 ... -2.384 1.878\n",
       "    va       (lat, lon, year, month) float64 0.08719 0.1337 ... -1.478 -2.785\n",
       "    nino     (year, month) float64 -0.4072 -0.2024 -0.1039 ... -1.177 -1.365"
      ]
     },
     "execution_count": 401,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "SODA=SODA.stack(time2=[\"year\",\"month\"])#去除标签重复值\n",
    "SODA=SODA.unstack(\"time2\")\n",
    "SODA"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 392,
   "metadata": {},
   "outputs": [
    {
     "ename": "AttributeError",
     "evalue": "'str' object has no attribute 'dims'",
     "output_type": "error",
     "traceback": [
      "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[0;31mAttributeError\u001b[0m                            Traceback (most recent call last)",
      "\u001b[0;32m<ipython-input-392-de992393b391>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mxr\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcombine_by_coords\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mSODA\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/combine.py\u001b[0m in \u001b[0;36mcombine_by_coords\u001b[0;34m(datasets, compat, data_vars, coords, fill_value, join, combine_attrs)\u001b[0m\n\u001b[1;32m    758\u001b[0m     \u001b[0;32mfor\u001b[0m \u001b[0mvars\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdatasets_with_same_vars\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mgrouped_by_vars\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    759\u001b[0m         combined_ids, concat_dims = _infer_concat_order_from_coords(\n\u001b[0;32m--> 760\u001b[0;31m             \u001b[0mlist\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mdatasets_with_same_vars\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    761\u001b[0m         )\n\u001b[1;32m    762\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/combine.py\u001b[0m in \u001b[0;36m_infer_concat_order_from_coords\u001b[0;34m(datasets)\u001b[0m\n\u001b[1;32m     52\u001b[0m     \u001b[0;31m# All datasets have same variables because they've been grouped as such\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m     53\u001b[0m     \u001b[0mds0\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mdatasets\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m---> 54\u001b[0;31m     \u001b[0;32mfor\u001b[0m \u001b[0mdim\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mds0\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mdims\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m     55\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m     56\u001b[0m         \u001b[0;31m# Check if dim is a coordinate dimension\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;31mAttributeError\u001b[0m: 'str' object has no attribute 'dims'"
     ]
    }
   ],
   "source": [
    "xr.combine_by_coords(SODA)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 391,
   "metadata": {},
   "outputs": [
    {
     "ename": "ValueError",
     "evalue": "cannot reindex or align along dimension 'year' because the index has duplicate values",
     "output_type": "error",
     "traceback": [
      "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[0;31mValueError\u001b[0m                                Traceback (most recent call last)",
      "\u001b[0;32m<ipython-input-391-4527a9b02e3a>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mxr\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mconcat\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mCMIP\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0mSODA\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m'mode'\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/concat.py\u001b[0m in \u001b[0;36mconcat\u001b[0;34m(objs, dim, data_vars, coords, compat, positions, fill_value, join, combine_attrs)\u001b[0m\n\u001b[1;32m    190\u001b[0m         )\n\u001b[1;32m    191\u001b[0m     return f(\n\u001b[0;32m--> 192\u001b[0;31m         \u001b[0mobjs\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdim\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdata_vars\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mcoords\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mcompat\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mpositions\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfill_value\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mjoin\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mcombine_attrs\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    193\u001b[0m     )\n\u001b[1;32m    194\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/concat.py\u001b[0m in \u001b[0;36m_dataset_concat\u001b[0;34m(datasets, dim, data_vars, coords, compat, positions, fill_value, join, combine_attrs)\u001b[0m\n\u001b[1;32m    382\u001b[0m     \u001b[0mdatasets\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0;34m[\u001b[0m\u001b[0mds\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcopy\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0;32mfor\u001b[0m \u001b[0mds\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mdatasets\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    383\u001b[0m     datasets = align(\n\u001b[0;32m--> 384\u001b[0;31m         \u001b[0;34m*\u001b[0m\u001b[0mdatasets\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mjoin\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mjoin\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mcopy\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;32mFalse\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mexclude\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mdim\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfill_value\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mfill_value\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    385\u001b[0m     )\n\u001b[1;32m    386\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/alignment.py\u001b[0m in \u001b[0;36malign\u001b[0;34m(join, copy, indexes, exclude, fill_value, *objects)\u001b[0m\n\u001b[1;32m    338\u001b[0m             \u001b[0mnew_obj\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mobj\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcopy\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mdeep\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mcopy\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    339\u001b[0m         \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 340\u001b[0;31m             \u001b[0mnew_obj\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mobj\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mreindex\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mcopy\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mcopy\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfill_value\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mfill_value\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0;34m**\u001b[0m\u001b[0mvalid_indexers\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    341\u001b[0m         \u001b[0mnew_obj\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mencoding\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mobj\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mencoding\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    342\u001b[0m         \u001b[0mresult\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mappend\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mnew_obj\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/dataset.py\u001b[0m in \u001b[0;36mreindex\u001b[0;34m(self, indexers, method, tolerance, copy, fill_value, **indexers_kwargs)\u001b[0m\n\u001b[1;32m   2551\u001b[0m             \u001b[0mfill_value\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   2552\u001b[0m             \u001b[0msparse\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;32mFalse\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 2553\u001b[0;31m             \u001b[0;34m**\u001b[0m\u001b[0mindexers_kwargs\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m   2554\u001b[0m         )\n\u001b[1;32m   2555\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/dataset.py\u001b[0m in \u001b[0;36m_reindex\u001b[0;34m(self, indexers, method, tolerance, copy, fill_value, sparse, **indexers_kwargs)\u001b[0m\n\u001b[1;32m   2582\u001b[0m             \u001b[0mcopy\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mcopy\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   2583\u001b[0m             \u001b[0mfill_value\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mfill_value\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 2584\u001b[0;31m             \u001b[0msparse\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0msparse\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m   2585\u001b[0m         )\n\u001b[1;32m   2586\u001b[0m         \u001b[0mcoord_names\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mset\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_coord_names\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;32m~/anaconda3/lib/python3.7/site-packages/xarray/core/alignment.py\u001b[0m in \u001b[0;36mreindex_variables\u001b[0;34m(variables, sizes, indexes, indexers, method, tolerance, copy, fill_value, sparse)\u001b[0m\n\u001b[1;32m    550\u001b[0m                 raise ValueError(\n\u001b[1;32m    551\u001b[0m                     \u001b[0;34m\"cannot reindex or align along dimension %r because the \"\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 552\u001b[0;31m                     \u001b[0;34m\"index has duplicate values\"\u001b[0m \u001b[0;34m%\u001b[0m \u001b[0mdim\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    553\u001b[0m                 )\n\u001b[1;32m    554\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;31mValueError\u001b[0m: cannot reindex or align along dimension 'year' because the index has duplicate values"
     ]
    }
   ],
   "source": [
    "xr.concat([CMIP,SODA],'mode')"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "pytorch",
   "language": "python",
   "name": "pytorch"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.6"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}